Skip to content
Snippets Groups Projects
Verified Commit d17de3bb authored by Tobias Hangleiter's avatar Tobias Hangleiter
Browse files

Fix axis limits in presence of nans

parent fa417b2b
Branches
Tags
1 merge request!68Bugfixes and improvements
Pipeline #1688373 waiting for manual action
......@@ -694,8 +694,8 @@ class PlotManager:
ydata = self.lines[key][plot][line]['line'].get_ydata()[
(left <= xdata) & (xdata <= right)
]
top = max(top, ydata.max())
bottom = min(bottom, ydata.min())
top = max(top, np.nanmax(ydata))
bottom = min(bottom, np.nanmin(ydata))
# Transform to correct scale
transform = self.axes[plot][line].transScale
top, bottom = transform.transform([(1, top),
......
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment