an iteration on Sporthorse Foal Registrations by phoebebright
an example of using d3 + crossfilter together to make an svg map with linked bar charts
these additions and modifications were made made along the way:
.style('white-space', 'nowrap')
so that for Northern Ireland
and 1999
the bar’s text fit’s within the bar’s heightcf
crossfilter object is filtered for only that county. then, updateMap
function is called, which re-renders the map with only the selected county shaded. on mouseout of the county bar, the cf object is unfiltered and the updatemMap
function is called once again. Now all of the counties on the map have data-driven fill colors.index.html
and into a separate file, ireland.svg
. this is more difficult that you might think. these links proved to be quite helpful:d3 google group thread on working with external svg files
jsfiddle with .each() technique
a comment:
when you mouse over the bar for Northern Ireland, none of those counties are shaded, even though there appears to be data for those counties. this is something to investigate more. if you know why this is, tweet at me or comment on the github gist.
forked from micahstubbs‘s block: Sporthorse Foal Registrations II