Skip to content

Commit

Permalink
Merge pull request #376 from MannLabs/fix_plotting
Browse files Browse the repository at this point in the history
fix plotting
  • Loading branch information
mschwoer authored Nov 19, 2024
2 parents 13b67bf + 88e5d7e commit d158b39
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion alphastats/gui/utils/analysis_helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,8 @@ def _display(
def display_figure(plot: PlotlyObject) -> None:
"""Display plotly or seaborn figure."""
try:
st.plotly_chart()
# calling plot.update_layout is vital here as it enables the savefig function to work
st.plotly_chart(plot.update_layout(plot_bgcolor="white"))
except Exception:
st.pyplot(plot)

Expand Down

0 comments on commit d158b39

Please sign in to comment.