Google Chart API

From Wikipedia, the free encyclopedia
Google Chart API
Original author(s) Google
Initial release 2007
Stable release February 2010
Website https://developers.google.com/chart/

The Google Chart API is a tool that lets web application developers create charts from some data and embed it in a web page.

Many types of charts are supported, and by making the request into an image tag, people can simply include the chart in a web page.

History

Originally, Google offered charts as a PNG image of a chart from data and formatting parameters in an HTTP request.

But since April 2012 Google is now using SVG (VML for older browsers) to draw the charts. The Google Image Charts API is deprecated (but still works).

Originally it was an internal tool to support rapid embedding of charts within Google's own applications (like Google Finance for example). Google decided it would be a useful tool to make available to web developers. It officially launched on December 6, 2007.[1]

Currently, line, bar, pie and radar charts, as well as Venn diagrams, scatter plots, sparklines, maps, google-o-meters, and QR codes are supported.

Example

The following URL creates the pie chart below:
http://chart.apis.google.com/chart?
chs=200x200
&chdlp=b
&chtt=Uberman
&chdl=Asleep|Awake
&chd=t:1,11,1,11,1,11,1,11,1,11,1,11
&cht=p
&chco=586F8E|7D858F

Open source implementation

Instead of creating the URL request manually, there are many open source external libraries available for most programming languages.

Platform Name Website
Java Google Chart API wrapper [2] http://code.google.com/p/googlechartwrapper/
Java charts4j [3] http://code.google.com/p/charts4j/
C#/.NET ngchart http://code.google.com/p/ngchart/
Ruby gchart http://rubyforge.org/projects/gchart
Python google-chartwrapper http://code.google.com/p/google-chartwrapper/
PHP gchartphp http://code.google.com/p/gchartphp/
Perl Google::Chart https://metacpan.org/pod/Google::Chart

Besides libraries, Eastwood Charts is an Open Source compatible version of Google Charts. It uses encodings that match the Google Chart API and adds its own features such as trendline overlay, 3D effects for bar charts, etc. Eastwood Charts install on its own Java Servlet server and won't send their data to Google for processing.

References

External links

This article is issued from Wikipedia. The text is available under the Creative Commons Attribution/Share Alike; additional terms may apply for the media files.