pyvista.Plotter.export_html#
- Plotter.export_html(filename) StringIO | None [source]#
Export this plotter as an interactive scene to a HTML file.
- Parameters:
- filename
str
|Path
Path to export the html file to.
- filename
- Returns:
StringIO
If filename is None, returns the HTML as a StringIO object.
Notes
You will need
trame
installed.Examples
>>> import pyvista as pv >>> from pyvista import examples >>> mesh = examples.load_uniform() >>> pl = pv.Plotter(shape=(1, 2)) >>> _ = pl.add_mesh(mesh, scalars='Spatial Point Data', show_edges=True) >>> pl.subplot(0, 1) >>> _ = pl.add_mesh(mesh, scalars='Spatial Cell Data', show_edges=True) >>> pl.export_html('pv.html')