Displaying a Plotly Plot in zero-true
Displaying a Plotly Plot
Plotly is one of the most popular plotting libraries in the python ecosystem, and zero-true has built in integrations for working with it. There is some slight nuance to how to work with plotly in zero-true though so take a look at the example below:
Run the cell in your notebook, and watch the line plot appear below! Plotly components require an ID as well as a plotly figure passed as arguments to render. Since plotly plots are static components in zero-true there are no values for you to access that users interact with. However you can set interactivity into the plot by using things like hovertext etc that are built into the plotly library!
Interactive Plotly Plots in Zero-True
Let’s take the code above and make it a little bit more exciting by interactively setting the last Y value in the plot:
Combining plotly’s incredible plotting capabilities with zero-true’s interactive notebook and UI can help take your visualization game to the next level.