Measurements.jl icon indicating copy to clipboard operation
Measurements.jl copied to clipboard

Plots.jl integration: grouping data leads to wrong errorbars

Open lukas-weber opened this issue 7 months ago • 1 comments

(Originally I had opened JuliaPlots/Plots.jl#4917, but then I realized the recipe is actually in this repository.)

If you use the group keyword with Measurement data, the errorbars of different data points get silently mixed up:

using Measurements
using Plots

data = range(0, 1, 10) .± range(0, 1, 10)
ids = mod.(1:10, 2)

plot(
   plot(data, title="expected errorbars"),
   plot(data, group=ids, title="wrong errorbars")
)

error

lukas-weber avatar Jul 24 '24 19:07 lukas-weber