Altair – A declarative statistical visualization library for Python
1–10 of 45 posts
Re: Altair – A declarative statistical visualization library for Python
#2Re: Altair – A declarative statistical visualization library for Python
#3Re: Altair – A declarative statistical visualization library for Python
#4Re: Altair – A declarative statistical visualization library for Python
#5would it be possible to link this up with multiple user selectible legend that then update a table? What I'm thinking is a table with multipl entires, where the legend on the right of the plot serves specify characterstics in the table. E.g. gender, age group, and then these selections would plot them but also update the table below them?
https://altair-viz.github.io/gallery/scatter_linked_table.ht...
Re: Altair – A declarative statistical visualization library for Python
#6would it be possible to link this up with multiple user selectible legend that then update a table? What I'm thinking is a table with multipl entires, where the legend on the right of the plot serves specify characterstics in the table. E.g. gender, age group, and then these selections would plot them but also update the table below them?
Personally I would look into plotly / dash for something with interactivity.
Re: Altair – A declarative statistical visualization library for Python
#7would it be possible to link this up with multiple user selectible legend that then update a table? What I'm thinking is a table with multipl entires, where the legend on the right of the plot serves specify characterstics in the table. E.g. gender, age group, and then these selections would plot them but also update the table below them?
Yes it's theoretically possible. I created an example of linking a table to a scatter plot brush selection. That said, I have never been able to get altair/vega-lite to generate a nicely formatted table to my satisfaction. I mostly end up connecting a simpler altair chart without interactions to a dataframe and hook them together using something like ipywidgets, Panel, or streamlit. It would be really nice though to…
Re: Altair – A declarative statistical visualization library for Python
#8Earlier quoted context omitted.
Yes it's theoretically possible. I created an example of linking a table to a scatter plot brush selection. That said, I have never been able to get altair/vega-lite to generate a nicely formatted table to my satisfaction. I mostly end up connecting a simpler altair chart without interactions to a dataframe and hook them together using something like ipywidgets, Panel, or streamlit. It would be really nice though to…
Thanks. Yeah that's not quite what I was hoping for, I was actually thinking something closer like the following: https://www.m43lenses.com/
The place where you start to run into problems is if you want to filter the table based on interactions with the chart. If you're going to use dropdowns and checkboxes to filter the dataframe and the chart then you have a lot of good options.
Re: Altair – A declarative statistical visualization library for Python
#9would it be possible to link this up with multiple user selectible legend that then update a table? What I'm thinking is a table with multipl entires, where the legend on the right of the plot serves specify characterstics in the table. E.g. gender, age group, and then these selections would plot them but also update the table below them?
I've seen this done by making a fake legend out of a bar chart. As far as I know, there's no way to make an interactive legend in Altair. Personally I would look into plotly / dash for something with interactivity.
https://altair-viz.github.io/gallery/interactive_legend.html
https://altair-viz.github.io/user_guide/interactions.html#se...
Re: Altair – A declarative statistical visualization library for Python
#10Earlier quoted context omitted.
Thanks. Yeah that's not quite what I was hoping for, I was actually thinking something closer like the following: https://www.m43lenses.com/
ipywidgets + altair could mimic that pretty easily I think since with that example you just want to filter with a bunch of checkmarks/radios/dropdowns on a sidebar and then display a chart and table based on those filters. The place where you start to run into problems is if you want to filter the table based on interactions with the chart. If you're going to use dropdowns and checkboxes to filter the dataframe and t…
So basically use ipwidgets to create the checkmarks/radio/dropdowns. Then hook the database up to altair. I'll play tommorow with altair and ipywidgets and see how I can cook this up.
"filter the table based on interactions with the chart" For me all I'd need is a the corresponding datapoint selected to highlight the row.