Add option for error bar styles#4360
Conversation
Should fix issue in JuliaPlots#4347
…-pgfplotsx-patch Updated variable names in `pgfplotsx.jl`
|
How do you feel about making this work like using Plots
using Random
Random.seed!(1234)
x = collect(1:10)
y = randn(length(x))
yerr = x ./ x .* 1.0
xerr = yerr ./ 5
plot(x, y, linestyle = :dash)
yerror!(x,y, yerror = yerr, linestyle = :solid)
xerror!(x,y, xerror = xerr, linestyle = :dot)? If not, we'd had to at least rename |
This is a good idea. I think having the option in |
… with `_linestyle` appended.
Codecov ReportBase: 80.57% // Head: 80.58% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## master #4360 +/- ##
==========================================
+ Coverage 80.57% 80.58% +0.01%
==========================================
Files 28 28
Lines 7319 7324 +5
==========================================
+ Hits 5897 5902 +5
Misses 1422 1422
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
|
I am actually against introducing a new attribute for that. What would be reasonable is, since |
|
Can this be merged ? |
|
In principle yes, we still have the issue that GR does not support markerstrokestyle.. I opened an issue at GR.jl |
|
I see, jheinen/GR.jl#470. |


Currently, the error bar lines follow the same line style as the series:
However, error bars should usually be solid, or at least customisable. In this PR, I have added options
:yerrorstyleand:xerrorstyle, along with aliases, to control this style working on the recipe level, and as such should apply to all/most backends.The result is changing the plot to:
I haven't added any tests, as I am not sure the best way to do this. Any feedback would be appreciated!