How to fix y-axis guidelines in place while the markers that overflows are pushed down

So, what I’m trying to do it is basically what you can see in the image:

Expected Behaviour

I want the y-axis guidelines to stay fixed in place and whenever a value overflows the highest value from the guidelines, then it would be squished/resized down.

But this is what is happening at the moment:

Current Behaviour

So far I tried adding the following settings to the yaxis layout config:

fixedrange: true

range: [0, 45], // set the fixed range of the y-axis

automargin: true, // add margins around the fixed range of the y-axis

autosize: true,

Show a more complete version of your plotly code. Maybe there’s a syntax error. Fixedrange will basically enable or disable zoom. That could, or could not be what you’re after. But I think you can just directly define the range, and that should work.

fig.update_layout(yaxis_range=[0,45])