allow missing in line_z, fill_z and marker_z
This commit is contained in:
parent
2816b1128f
commit
bb3c54cb27
@ -527,9 +527,9 @@ function get_clims(sp::Subplot)
|
|||||||
z_colored_series = (:contour, :contour3d, :heatmap, :histogram2d, :surface)
|
z_colored_series = (:contour, :contour3d, :heatmap, :histogram2d, :surface)
|
||||||
for series in series_list(sp)
|
for series in series_list(sp)
|
||||||
for vals in (series[:seriestype] in z_colored_series ? series[:z] : nothing, series[:line_z], series[:marker_z], series[:fill_z])
|
for vals in (series[:seriestype] in z_colored_series ? series[:z] : nothing, series[:line_z], series[:marker_z], series[:fill_z])
|
||||||
if (typeof(vals) <: AbstractSurface) && (eltype(vals.surf) <: Real)
|
if (typeof(vals) <: AbstractSurface) && (eltype(vals.surf) <: Union{Missing, Real})
|
||||||
zmin, zmax = _update_clims(zmin, zmax, ignorenan_extrema(vals.surf)...)
|
zmin, zmax = _update_clims(zmin, zmax, ignorenan_extrema(vals.surf)...)
|
||||||
elseif (vals != nothing) && (eltype(vals) <: Real)
|
elseif (vals != nothing) && (eltype(vals) <: Union{Missing, Real})
|
||||||
zmin, zmax = _update_clims(zmin, zmax, ignorenan_extrema(vals)...)
|
zmin, zmax = _update_clims(zmin, zmax, ignorenan_extrema(vals)...)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@ -654,7 +654,7 @@ function has_attribute_segments(series::Series)
|
|||||||
end
|
end
|
||||||
series[:seriestype] == :shape && return false
|
series[:seriestype] == :shape && return false
|
||||||
# ... else we check relevant attributes if they have multiple inputs
|
# ... else we check relevant attributes if they have multiple inputs
|
||||||
return any((typeof(series[attr]) <: AbstractVector && length(series[attr]) > 1) for attr in [:seriescolor, :seriesalpha, :linecolor, :linealpha, :linewidth, :fillcolor, :fillalpha, :markercolor, :markeralpha, :markerstrokecolor, :markerstrokealpha]) || any(typeof(series[attr]) <: AbstractArray{<:Real} for attr in (:line_z, :fill_z, :marker_z))
|
return any((typeof(series[attr]) <: AbstractVector && length(series[attr]) > 1) for attr in [:seriescolor, :seriesalpha, :linecolor, :linealpha, :linewidth, :fillcolor, :fillalpha, :markercolor, :markeralpha, :markerstrokecolor, :markerstrokealpha]) || any(typeof(series[attr]) <: AbstractArray for attr in (:line_z, :fill_z, :marker_z))
|
||||||
end
|
end
|
||||||
|
|
||||||
# ---------------------------------------------------------------
|
# ---------------------------------------------------------------
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user