plotly.py icon indicating copy to clipboard operation
plotly.py copied to clipboard

[BUG] Slider changes don't trigger axes (x, y, colorbar) adjustments

Open celia-lm opened this issue 1 year ago • 0 comments

When the slider moves, the axes don't adjust to the new data range, but if we download the plot with the current slider selection the view is correct.

https://github.com/user-attachments/assets/9305c8f8-4724-4b96-9f0f-dbaf5159df4c

MRE

plotly==5.24.1

import plotly.express as px
import random

df = px.data.gapminder()
df['numeric_var'] = df['year'].apply(lambda x: x - 1900 + random.randint(-5,5))
fig = px.scatter(
    df, x="gdpPercap", y="numeric_var", animation_frame="year", animation_group="country",
    color="numeric_var", hover_name="country",
    )
fig.show()

celia-lm avatar Oct 11 '24 17:10 celia-lm