Hacker News new | ask | show | jobs
by chriddyp-plotly 3288 days ago
Thank you @jarpineh!

> Have you thought about Gapminder like animations?

Definitely. The user guide actually walks you through creating an app with world indicator data. Check out the last example here: https://plot.ly/dash/getting-started-part-2. As you hover over points in the scatter plot, the time series updates with data corresponding to that point. A slider below the chart filters the scatter plot by year.

We recently added animations to plotly.js (the graphing library that's used by Dash) so that points can transition smoothly between states. That's accessible in dash by setting `animate=True` in the `dash_core_components.Graph` component.

One of the neat things about Dash is that you have full control over the visuals and the analytics. So you could easily update this example to display the "trails" behind the scatter plots as they are animating or programatically filter or aggregate the data before plotting it.

> Could you elaborate on what options there is for visualizing geographic information?

Plotly.js uses MapboxGL under the hood for satellite scatter and line plots. We also have lower-resolution SVG-based world and USA maps for choropleths, line, and scatter plots. You can see some examples of community generated maps in the feed: https://plot.ly/feed/?q=plottype:scattermapbox or just play around in the chart editor (https://plot.ly/create) to get a sense of what's available.

Through the `scattermapbox` chart type you can plot custom shapefiles but we can't yet color those shapefiles through a data array. We're looking for a company to help sponsor improvements like these.

1 comments

Thank you for your answers and thanks so much for open sourcing Dash!

I'll be definitely testing these examples with our data. Plotly seems to have grown leaps and bounds from when I last tried it year or so ago.

I believe we could integrate our data browser's React components into or alongside with Dash. This way data could flow directly from our APIs.

We have our geographic shapes in Geoserver, so GeoJSON would be the easiest way to get them into browser or Python for Dash. I have to see what how this could be adapted. If this were Django based I'd be using GeoDjango, but Postgis should be accessible from Flask as well.