Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Altair + ipywidgets #290

Closed
SylvainCorlay opened this issue Jan 9, 2017 · 8 comments
Closed

Altair + ipywidgets #290

SylvainCorlay opened this issue Jan 9, 2017 · 8 comments
Milestone

Comments

@SylvainCorlay
Copy link
Contributor

Now that we have a proper way to render widgets on

and

It would be interesting to make an altair widget instead of only using a custom mime type in the output.

The benefit would be that we would be able to lay out altair charts with other widgets.

@gnestor
Copy link
Collaborator

gnestor commented Feb 8, 2017

I'm sure you've seen this, but if not: https://github.com/altair-viz/altair_widgets

Are you proposing that ipywidgets provide an altair widget or that altair provide an altair widget?

@SylvainCorlay
Copy link
Contributor Author

I am proposing that altair charts can be jupyter widgets.

@ellisonbg
Copy link
Collaborator

Eventually I would like to see regular MIME output and widgets supported.

@ellisonbg ellisonbg added this to the Backlog milestone Apr 19, 2017
@ellisonbg
Copy link
Collaborator

I think the direction to go with this is to have a Vega-Lite rendering widget that is simple and only has data and spec attributes. The difficulty is that the Vega-Lite JS API doesn't have a fine grained JS API that allows you to update things dynamically. But a basic widget like that would be great.

@choldgraf
Copy link
Contributor

Hey all - just wondering if there's been any movement on this front? I've been playing around more with Altair and think it's awesome! It would be even more awesome if this could play nicely with the Jupyter Widgets ecosystem, rather than requiring to use one or the other (e.g. make a dropdown in jupyter widgets that, when clicked, changes something in an altair chart)

@jakevdp
Copy link
Collaborator

jakevdp commented Feb 6, 2019

make a dropdown in jupyter widgets that, when clicked, changes something in an altair chart

That would maybe be possible, but it's more of a Vega-Lite question than an Altair question. All Altair does is create JSON specifications that are rendered by the vega javascript stack: Altair itself contains no javascript.

@choldgraf
Copy link
Contributor

@jakevdp good to know, thx!

@joelostblom
Copy link
Contributor

It is now possible to use the JupyterChart class to create Altair charts that can interact with jupyter/ipywidgets directly. See this section in the docs for details https://altair-viz.github.io/user_guide/jupyter_chart.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants