Skip to content

Commit

Permalink
cure error when extremes cannot be found (#1011)
Browse files Browse the repository at this point in the history
  • Loading branch information
HDembinski authored Jul 29, 2024
1 parent 4965147 commit 1bf5af2
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/iminuit/minuit.py
Original file line number Diff line number Diff line change
Expand Up @@ -2218,8 +2218,9 @@ def draw_mnmatrix(
extremes.append(x[k - 1])
if yk > fmax and y[k - 1] < fmax:
extremes.append(xk)
a = min(*extremes, a)
b = max(*extremes, b)
if extremes:
a = min(*extremes, a)
b = max(*extremes, b)
prange[par1] = (a, b)
plt.ylim(0, fmax + 0.5)
for j in range(i):
Expand Down

0 comments on commit 1bf5af2

Please sign in to comment.