Recently, I exported a plot to html in order to embed into a webpage for a school project. The embed works perfectly, however the group noticed the embed looks a bit small. Is there something in the html that would allow for us to adjust the width and height values of the table?
1 Like
Hi @Atros04
Could you share a minimum, reproducible code example? That would make it much easier to propose solutions. Thanks.
Hi Marc,
I found the issue where I did not define the height
and width
of my plot when defining the variable. The code was:
plot = plot_df.hvplot.scatter(x="households_median_income_dollars",
y="households_percent_allocated_household_income_in_the_past_12_mo",
by="Class",
use_index=True,
hover_cols='all',
# Import resource management and save the plot as html
from bokeh.resources import INLINE
hvplot.save(plot, 'affordable_housing_plot.html', resources=INLINE)
1 Like
Is here way to resize html plot automatically?
if I save .html with
- pure plotly it can be resized according browser window. which is very nice.
- hvplot it dont change size automatically.
can I have both from 2 worlds?
hvPlot supports responsive=True as an argument, which you may want to combine with a min_width and min-height.
1 Like