-
-
Notifications
You must be signed in to change notification settings - Fork 352
Open
Labels
(tri)contour(f)not 3D contour, that's volumenot 3D contour, that's volumeAttributesPlot, Block and Scene AttributesPlot, Block and Scene AttributesMakieBackend independent issues (Makie core)Backend independent issues (Makie core)bugcolorscolor, colormap, colorrange, alpha, etccolor, colormap, colorrange, alpha, etcgood first issueThis should come with some instructions!This should come with some instructions!
Description
- are you running newest version (version from docs) ?
- can you reproduce the bug with a fresh environment ? (
]activate --temp; add Makie
) - What platform + GPU are you on?
MWE:
contourf(randn(10, 10); colorrange = (0, 1))
It looks like the color attributes are specified explicitly (instead of using the new mixin
functions). We could change this to use eg MakieCore.mixin_colormap_attributes()...
instead. The implementation would have to be updated to pass all of the color attributes through to the color determining function as well.
Makie.jl/src/basic_recipes/contourf.jl
Lines 7 to 42 in c4e3b7b
@recipe Contourf begin | |
""" | |
Can be either | |
- an `Int` that produces n equally wide levels or bands | |
- an `AbstractVector{<:Real}` that lists n consecutive edges from low to high, which result in n-1 levels or bands | |
If `levels` is an `Int`, the contourf plot will be rectangular as all `zs` values will be covered edge to edge. | |
This is why `Axis` defaults to tight limits for such contourf plots. | |
If you specify `levels` as an `AbstractVector{<:Real}`, however, note that the axis limits include the default margins because the contourf plot can have an irregular shape. | |
You can use `tightlimits!(ax)` to tighten the limits similar to the `Int` behavior. | |
""" | |
levels = 10 | |
""" | |
Determines how the `levels` attribute is interpreted, either `:normal` or `:relative`. | |
In `:normal` mode, the levels correspond directly to the z values. | |
In `:relative` mode, you specify edges by the fraction between minimum and maximum value of `zs`. | |
This can be used for example to draw bands for the upper 90% while excluding the lower 10% with `levels = 0.1:0.1:1.0, mode = :relative`. | |
""" | |
mode = :normal | |
colormap = @inherit colormap | |
colorscale = identity | |
""" | |
In `:normal` mode, if you want to show a band from `-Inf` to the low edge, | |
set `extendlow` to `:auto` to give the extension the same color as the first level, | |
or specify a color directly (default `nothing` means no extended band). | |
""" | |
extendlow = nothing | |
""" | |
In `:normal` mode, if you want to show a band from the high edge to `Inf`, set `extendhigh` | |
to `:auto` to give the extension the same color as the last level, or specify a color directly | |
(default `nothing` means no extended band). | |
""" | |
extendhigh = nothing | |
# TODO, Isoband doesn't seem to support nans? | |
nan_color = :transparent | |
MakieCore.mixin_generic_plot_attributes()... |
anneaux
Metadata
Metadata
Assignees
Labels
(tri)contour(f)not 3D contour, that's volumenot 3D contour, that's volumeAttributesPlot, Block and Scene AttributesPlot, Block and Scene AttributesMakieBackend independent issues (Makie core)Backend independent issues (Makie core)bugcolorscolor, colormap, colorrange, alpha, etccolor, colormap, colorrange, alpha, etcgood first issueThis should come with some instructions!This should come with some instructions!