block by mpmckenna8 fcb2c2306c2bf249b719

d3 data() to load brazil w/ cities map

Full Screen

This map uses data() to load the data and so I also use enter(). I didn’t, however, use exit(). Not sure if this is bad form or not really necessary, or could me necessary if I was doing some other kind of data loading….

Anyways if you click on a given city (the circles) the name should be printed to your javascript console. Also the bigger circles are cities in Brazil w/ more than 100,000 people. Looks like there are a lot more big cities in Brazil than I had thought…. 123 according to the population stats w/ Natural Earth’s populated places dataset.

I think I also want the amazon in my next map so I have to get to making that dataset.

index.html