anynan isfinite; error on reusing layout
This commit is contained in:
parent
a5ddebf44d
commit
e5c4f782a5
@ -479,6 +479,8 @@ function build_layout(layout::GridLayout, n::Integer)
|
||||
append!(subplots, sps)
|
||||
merge!(spmap, m)
|
||||
i += length(sps)
|
||||
elseif isa(l, Subplot)
|
||||
error("Subplot exists. Cannot re-use existing layout. Please make a new one.")
|
||||
end
|
||||
i >= n && break # only add n subplots
|
||||
end
|
||||
|
||||
@ -152,7 +152,7 @@ function iter_segments(args...)
|
||||
end
|
||||
|
||||
# helpers to figure out if there are NaN values in a list of array types
|
||||
anynan(i::Int, args...) = any(a -> isnan(cycle(a,i)), args)
|
||||
anynan(i::Int, args...) = any(a -> !isfinite(cycle(a,i)), args)
|
||||
anynan(istart::Int, iend::Int, args...) = any(i -> anynan(i, args...), istart:iend)
|
||||
allnan(istart::Int, iend::Int, args...) = all(i -> anynan(i, args...), istart:iend)
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user