I am currently trying to use a custom Google Map with GeoCharts, as I need to define certain areas in a county.
I have a KML that has the defined areas, but I see you are loading in JS files, rather than a KML. How do I get my map data in JS format like you have? Hope you can point me in the right direction! On Thursday, 26 May 2016 15:24:43 UTC+1, Oscar Diaz wrote: > > Hello everyone, > > I am working on a project for the www.nefb.org site( > http://www.nefb.org/tpp). As for now, I want every county to have > different farm information, but it won't let me add a fourth line of info > and I need 7 lines of info per county. > > This is the script: > > <!doctype html> > <html> > <head> > <script type="text/javascript" src=" > https://www.gstatic.com/charts/loader.js"></script> > <script type="text/javascript" src="https://www.google.com/jsapi > "></script> > > <script type="text/javascript"> > google.load('visualization', '1', { > packages: ['geochart'], > callback: drawVisualization > }); > > > function drawVisualization() { > var data = new google.visualization.DataTable(); > data.addColumn('string', 'Province'); // Implicit domain label col. > data.addColumn('number', 'Pork'); // Implicit series 1 data col. > data.addColumn({type:'string', role:'tooltip'}); // > data.addRows([ > > [{v:"NE-1B",f:"Dodge"},1,"Pork $2,205,270"], > > /** > var data = google.visualization.arrayToDataTable([ > > > ['Country', 'Pork', 'Cattle'], > ['NE-1B', 787905, 1659198], ** Dodge ** > ['NE-02', 2573422, 3011952], /** Antelope ** > ['NE-03', 0, 429964 ], /** Blaine ** > ['NE-04', 0, 1301768], /** Banner ** > ['NE-05', 0, 0], /** Arthur ** > ['NE-1C', 0, 0], /** Douglas ** > ['NE-1D', 0, 1332172], /** Dundy ** > ['NE-1E', 681644, 878709], /** Fillmore ** > ['NE-1F', 9612, 216143], /** Franklin ** > ['NE-20', 43932, 852830], /** Frontier ** > ['NE-21', 0, 579452], /** Furnas ** > ['NE-22', 863099, 386227], /** Gage ** > ['NE-23', 0, 0], /** Garden ** > ['NE-24', 0, 612593], /** Garfield ** > ['NE-25', 0, 0], /** Gosper ** > ['NE-26', 0, 0], /** Grant ** > ['NE-27', 0, 0], /** Greeley ** > ['NE-28', 59077, 1762478], /** Hall ** > ['NE-29', 160969, 1129601], /** Hamilton ** > ['NE-2A', 0, 1423933], /** Harlan ** > ['NE-2B', 0, 1339731], /** Hayes ** > ['NE-2C', 0, 307368], /** Hitchcock ** > ['NE-2D', 3601665, 3427361], /** Holt ** > ['NE-2E', 728, 224462], /** Hooker ** > ['NE-2F', 72524, 1946818], /** Howard ** > ['NE-30', 1678237, 454876], /** Jefferson ** > ['NE-31', 88931, 0], /** Johnson ** > ['NE-32', 0, 2558623], /** Kearney ** > ['NE-33', 0, 1319343], /** Keith ** > ['NE-34', 0, 1130256], /** Keya Paha ** > ['NE-35', 291, 143520], /** Kimball ** > ['NE-36', 0, 1974647], /** Knox ** > ['NE-37', 176260, 176602], /** Lancaster ** > ['NE-38', 1893, 7680021], /** Lincoln ** > ['NE-39', 0, 233287], /** Logan ** > **/ > ]); > > google.visualization.GeoChart.setMapsSource(' > http://chrisdblumberg.com/maps') > > var geochart = new google.visualization.GeoChart( > > document.getElementById('visualization')); > geochart.draw(data, {width: 650, height: 347, region:'US-NE', > resolution: 'provinces'}); > > google.visualization.events.addListener(geochart, 'regionClick', > function(r) { > console.log(r.region); > }); > } > </script> > </head> > > <body> > <div id="visualization"></div> > </body> > </html> > > -- 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 [email protected]. To post to this group, send email to [email protected]. Visit this group at https://groups.google.com/group/google-visualization-api. To view this discussion on the web visit https://groups.google.com/d/msgid/google-visualization-api/96ef3f3b-d995-4608-a8d9-35efe78af00f%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
