Google Charts API
Posted about 4 years ago on March 06, 2008
Wow, I just finished my first chart with the Google Charts API. I had a great use case for it and it delivered way above expectations.
I have started to work on an existing web site for "Hear The Cry" which is a ministry of Vineyard Church of Columbus. The feature request was to add a progress indicator for each project to visualize how the funding is progressing in terms of the project goal. Here is how it turned out: Link.
The API was incredibly easy to learn, thanks in part to the fact that the only interface to the API is via URL. Within 25 minutes I had something that looks like this:
Here is the URL which becomes the source in your img tag:
http://chart.apis.google.com/chart?cht=bhs&chs=200x50&chd=t:70|100&chco=F6D472,7AD3F7&chxt=x,y&chxl=1:|%%20Funded|0:|0|20|40|60|80|100&chf=bg,s,EBF8FE
And to update my funding status, I simply change &chd=t:70|100 to &chd=t:75|100. Cake!!!
Background/colors/and axis labels are all changeable via the URL. For a breakdown of each parameter and what it does you can hit the Google Charts Developer API docs.
With the understanding of the API and how it works now, I'm sure I could whip out some more complicated charts in no time - the API is very intuitive and straightforward.
Comments
Jesse writes...
I used the map API back in the day -- the site I used it on is still up too (http://www.columbuscityattorney.org/map.aspx) and it too was stupid simple to make work like you would expect. Toss in some values and get what you wanted out with no surprises. Gotta love it.
March 10, 2008
New Comment