You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Creating a bar plot with different colours for each bar no longer works after v1.11.0 (but works correctly on v1.10.6). It just gives all bars the colour which is first in the colour list (i.e. blue in MWE below).
julia> Plots.bar(ones(3), c=[:blue; :red; :green])
┌ Warning: Indices Base.OneTo(3) of attribute `seriescolor` does not match data indices 1:17.
└ @ Plots ~/.julia/packages/Plots/isZEW/src/utils.jl:123
┌ Info: Data contains NaNs or missing values, and indices of `seriescolor` vector do not match data indices.
│ If you intend elements of `seriescolor` to apply to individual NaN-separated segements in the data,
│ pass each segment in a separate vector instead, and use a row vector for`seriescolor`. Legend entries
│ may be suppressed by passing an empty label.
│ For example,
└ plot([1:2,1:3], [[4,5],[3,4,5]], label=["y"""], seriescolor=[12])
┌ Warning: Indices Base.OneTo(3) of attribute `fillcolor` does not match data indices 1:17.
└ @ Plots ~/.julia/packages/Plots/isZEW/src/utils.jl:123
┌ Info: Data contains NaNs or missing values, and indices of `fillcolor` vector do not match data indices.
│ If you intend elements of `fillcolor` to apply to individual NaN-separated segements in the data,
│ pass each segment in a separate vector instead, and use a row vector for`fillcolor`. Legend entries
│ may be suppressed by passing an empty label.
│ For example,
└ plot([1:2,1:3], [[4,5],[3,4,5]], label=["y"""], fillcolor=[12])
┌ Warning: Indices Base.OneTo(3) of attribute `markercolor` does not match data indices 1:17.
└ @ Plots ~/.julia/packages/Plots/isZEW/src/utils.jl:123
┌ Info: Data contains NaNs or missing values, and indices of `markercolor` vector do not match data indices.
│ If you intend elements of `markercolor` to apply to individual NaN-separated segements in the data,
│ pass each segment in a separate vector instead, and use a row vector for`markercolor`. Legend entries
│ may be suppressed by passing an empty label.
│ For example,
└ plot([1:2,1:3], [[4,5],[3,4,5]], label=["y"""], markercolor=[12])
The warnings disappear if we reshape the colour vector:
Details
Creating a bar plot with different colours for each bar no longer works after v1.11.0 (but works correctly on v1.10.6). It just gives all bars the colour which is first in the colour list (i.e. blue in MWE below).
MWE:
which outputs:
The warnings disappear if we reshape the colour vector:
but we still don't get the correct behaviour.
Backends
This bug occurs on ( insert
x
below )Versions
Plots.jl version: 1.11.0 onwards
Backend version (
]st -m <backend(s)>
): GR v0.55.0 & PyPlot v2.9.0Output of
versioninfo()
:Julia Version 1.6.0
Commit f9720dc2eb (2021-03-24 12:55 UTC)
Platform Info:
OS: Linux (x86_64-pc-linux-gnu)
CPU: Intel(R) Core(TM) i7-8700T CPU @ 2.40GHz
WORD_SIZE: 64
LIBM: libopenlibm
LLVM: libLLVM-11.0.1 (ORCJIT, skylake)
The text was updated successfully, but these errors were encountered: