New answers tagged d3
From Wikipedia: For a general sphere of radius r, any portion of its surface with area A = r2 subtends one steradian. So you can multiply your steradians value by r2 to get the area value. Using r = 6371 km: 8.101249039703731e-8 * (6371 * 6371) = 3.288 km²
In the unemployment choropleth example, rateById is a d3.map, which as far as I know can really only store two values. You have three: the origin, the destination, and the flow amount. I would load the data normally, like so: queue() .defer(d3.json, "data/us.json") .defer(d3.tsv, "data/commute.tsv") .await(ready); and then use a method like ...
queue() is for asynchronous loading of data. So assuming all of your data is loaded, you do not need to use queue() again after the data is loaded, and control is handed to ready by .await(ready). I think what you are looking for is to assign click behavior to the map. You can do this in ready, by referencing an onclick function map = ...
Top 50 recent answers are included