Can't export HTML with Plotly backend
See original GitHub issueWhen I use Plotly as backend, the exported HTML does not shows the plot correctly. When I click on the exported HTML file, only ''Drawing…" is displayed.
This is the python code I used in Jupyter notebook
import NumPy as np
import pandas as pd
import holoviews as hv
hv.extension('plotly')
df = pd.DataFrame()
df['x'] = np.arange(10)
df['y'] = np.arange(10)
plot = hv.Curve(df, 'x','y')
hv.save(plot, 'plot.html')
This is the source code of the exported HTML
<script type="text/javascript">window.PLOTLYENV=window.PLOTLYENV || {};</script>
<div id="120902428136.loading" style="color: rgb(50,50,50);">Drawing...</div><div id="120902428136" style="height: 600; width: 800;" class="plotly-graph-div"></div><script type="text/javascript"> var plotly = window._Plotly || window.Plotly;plotly.plot("120902428136", [{"legendgroup": "Curve", "line": {"color": "#30a2da", "width": 2}, "mode": "lines", "name": "", "showlegend": false, "x": [0, 1, 2, 3, 4, 5, 6, 7, 8, 9], "y": [0, 1, 2, 3, 4, 5, 6, 7, 8, 9], "type": "scatter", "uid": "2d9897e8-f9cb-4d8a-bdc3-fbf018ed4930"}], {"height": 400, "margin": {"b": 50, "l": 50, "pad": 4, "r": 50, "t": 50}, "title": {"text": ""}, "width": 400, "xaxis": {"range": [0.0, 9.0], "title": {"text": "x"}}, "yaxis": {"range": [0.0, 9.0], "title": {"text": "y"}}}, {"showLink": false}).then(function() {
var elem = document.getElementById("120902428136.loading"); elem.parentNode.removeChild(elem);
})</script>
It seems the data is included in the HTML file but for some reasons it is not shown.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:8 (5 by maintainers)
Top Results From Across the Web
Can't export HTML with Plotly backend · Issue #3683 - GitHub
I accidentally found out some plots can be exported to html using plotly backend. It seems that export works when there is extra...
Read more >How to save a panel to html with plotly backend?
Hello guys, I'm creating a panel dashboard with plotly graphs and I'm trying to save in html, but the graphs aren't appearing.
Read more >How to export a plotly dashboard app into a html standalone ...
You cannot have a fully encapsulated dashboard with interactivity in an HTML file alone. You must bring server-side logic to the table.
Read more >Interactive html export in Python - Plotly
HTML export in Dash¶ Dash is the best way to build analytical apps in Python using Plotly figures. To run the app below,...
Read more >Saving plot to html - General Usage - Julia Discourse
We want to save the contents of the figure in html (it's exactly the same ... with HTML, PlotlyJS.jl or Plotly.jl, or Plots.jl...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Yes, that should be in the next release. In the meantime, you can install from master using something like
pip install git+https://github.com/pyviz/holoviews.git@master#egg=holoviews
That comment doesn’t seem related to this issue…?