quickD3map
quickD3map copied to clipboard
Color and Size By Column
Allow users to specify a pandas dataframe to color by or to size-by.
The color code can be reused from the ggplot program once it solidifies. But the idea would be to determine the type of data - categorical, continuous, etc and choose an appropriate color scale for it.
The size column should also be at least a little bit intelligent about scales .
On the rendering size these properties should be passed as part of the Feature attributes of the Geojson feature collection. The template can then color by this value. All of the choice of color etc should be on the python/server side to allow maximum reuse of d3.js code with the goal of keeping template files as simple as possible.
column is added under point class. not sure how i'm gonna do color. It would be nice to do on the JS side but faster to implement on the python side (as a "color" feature in the TopoJson). Added colorbrewer files to be used but you have to be able to figure out what sort of variable and scale etc. i was hoping a nice solution would be implemented in ggplot and then we could just use that. But even without that a quick hack can be put togehter onthe python side.