You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm looking at the Globe Albersusa example and noticed that the properties of Geometry object is not available after feature_from_name returns. I need to access these properties to assign/map the FIPS county ID to each SVG subcomponent so I can map specific data to each county.
Here's the equivalent code in JS does this automatically without having to do any manual mapping:
ex:
// Draw county boundaries and fill accordinglysvg.selectAll("path").data(feature(usCounties,usCounties.objects.counties).features).enter().append("path").attr("d",path).attr("fill",d=>{constcountyData=countyToData[d.id];console.log(d,countyData);if(countyData){returnd3.color(colorScale(countyData.rise));}return"darkgrey";}).attr("stroke","#ffffff")// color of the border.attr("stroke-width","1.0");// thickness of the border;
How can i do something similar with d3_geo?
The text was updated successfully, but these errors were encountered:
I'm looking at the Globe Albersusa example and noticed that the properties of Geometry object is not available after
feature_from_name
returns. I need to access these properties to assign/map the FIPS county ID to each SVG subcomponent so I can map specific data to each county.Here's the equivalent code in JS does this automatically without having to do any manual mapping:
ex:
How can i do something similar with d3_geo?
The text was updated successfully, but these errors were encountered: