Reputation: 4364
what is wrong with ratio? (100,200)
https://chart.googleapis.com/chart?cht=p&chd=t:100,200&chs=300x120&chl=Hello|World
Upvotes: 2
Views: 167
Reputation: 6406
As marcog explained, by default values over 100 will be truncated to 100, thus causing your api call to be processed in the background as:
https://chart.googleapis.com/chart?cht=p&chd=t:100,100&chs=300x120&chl=Hello|World
which is why you see a pie chart with two equal pieces. One way to fix this is to add a custom scale to your data series using the chds parameter like this:
https://chart.googleapis.com/chart?cht=p&chd=t:100,200&chds=0,200&chs=300x120&chl=Hello|World
Note I added a &chds=0,200
to specify that values can range from 0 to 200.
Another option is to use percentages rather than actual values
Hope this helps.
Upvotes: 2
Reputation: 138387
The values need to be between 0 and 100, with values above 100 truncated to 100 (reference).
Upvotes: 1
Reputation: 14331
Had a quick mess around with the URL. Is it possible there's meant to be a "total" parameter in the URL? Since 3 parameters just splits it equally into 3 parts...
Upvotes: 0