Display Continents Names in GeoCharts

104 views
Skip to first unread message

Marco Slehiman

unread,
Nov 10, 2015, 3:39:00 PM11/10/15
to Google Visualization API
I'm trying to display sales data grouped by continent. And Geo charts is working as i want. Now i just want to display the continent name. But The Continent id is displayed.
When i use continent name as value, Geo chart does not display anything.
I will appreciate any comment or tip

Here is the json file used  and the options.

JSON

{
   
"cols": [{
           
"id": "",
           
"label": "Continent",
           
"pattern": "",
           
"type": "string"
       
}, {
           
"id": "",
           
"label": "Sales",
           
"pattern": "",
           
"type": "number"
       
}],
   
"rows": [{
           
"c": [{
                   
"v": "019",
                   
"f": null
               
}, {
                   
"v": 21497,
                   
"format": null
               
}]
       
}, {
           
"c": [{
                   
"v": "142",
                   
"f": null
               
}, {
                   
"v": 18386,
                   
"format": null
               
}]
       
}, {
           
"c": [{
                   
"v": "150",
                   
"f": null
               
}, {
                   
"v": 25819,
                   
"format": null
               
}]
       
}]
}


Options

            var options2 = {'region': '019', 'width': 400, 'height': 300, 'resolution': 'continents'};




Thank you
Marco Slehiman

Sergey Grabkovsky

unread,
Nov 10, 2015, 3:41:58 PM11/10/15
to Google Visualization API
Hi Marco,

If you provide a formatted value for each cell (the 'f' property), that will be displayed instead of the actual value.

--
You received this message because you are subscribed to the Google Groups "Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-visualizati...@googlegroups.com.
To post to this group, send email to google-visua...@googlegroups.com.
Visit this group at http://groups.google.com/group/google-visualization-api.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-visualization-api/1618463d-cf07-48fa-9f62-5ef300d098ef%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
unnamed.gif 
Sergey Grabkovsky | SWE  | gra...@google.com
Reply all
Reply to author
Forward
0 new messages