basic_map = {
const svg = d3
.create("svg")
.attr("width", 6000)
.attr("height", 600);
const paths = svg
.selectAll("g")
.data(topojson.feature(us, us.objects.states).features)
.join("path")
.style("stroke", "white")
.style("fill", d => {
if (state.includes(d.properties.name)) {
var color_value = nested_data
.find(state => state.key == d.properties.name)
.values.find(x => x.key == categories).value;
}
return color_scale(color_value);
})
.attr("d", d => path(d));
return svg.node();
}