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
I found something wrong in error bar.
For example, x=abs([-1:0.4:0,-1:0.4:1,0.2:0.4:1]); y=rand(1,12); err=rand(1,12); tag0=cell(3,1);tag0=cellfun(@(x) 'a',tag0,'UniformOutput',false); tag1=cell(3,1);tag1=cellfun(@(x) 'b',tag1,'UniformOutput',false); tag=[tag1;tag0;tag0;tag1]; g=gramm('x',x,'y',y,'ymin',y-err,'ymax',y+err); g.facet_wrap(tag); g.geom_line; g.geom_interval('geom','errorbar'); g.draw;
You can see that the errorbar do not has the horizontal line.
If we just change the tag like: tag=[tag1;tag1;tag0;tag0];
or change the x like: x=-1:0.2:1.2;
It's going to be normal now.
The text was updated successfully, but these errors were encountered:
Gery111
changed the title
error 偶发
errorbar do not has horizontal line
Jan 26, 2020
You are using a pretty vicious dataset ! The bug seems related to the functionality that "dodges" graphical elements so that they are not superimposed. Your code specifically generates multiple error bars at the same x location which are however in the same data group, with x data that is additionally not ordered. I'll look into it !
Thank you.
Actually, the way of the simulated data is like my real data. Those two error bars at same x location are in the different group, which I didn't show it here. Because it's no horizontal line, error bars are overlaped, and I can't discriminate the error bars from two groups.
Hi,
I found something wrong in error bar.
For example,
x=abs([-1:0.4:0,-1:0.4:1,0.2:0.4:1]); y=rand(1,12); err=rand(1,12); tag0=cell(3,1);tag0=cellfun(@(x) 'a',tag0,'UniformOutput',false); tag1=cell(3,1);tag1=cellfun(@(x) 'b',tag1,'UniformOutput',false); tag=[tag1;tag0;tag0;tag1]; g=gramm('x',x,'y',y,'ymin',y-err,'ymax',y+err); g.facet_wrap(tag); g.geom_line; g.geom_interval('geom','errorbar'); g.draw;
You can see that the errorbar do not has the horizontal line.
If we just change the tag like:
tag=[tag1;tag1;tag0;tag0];
or change the x like:
x=-1:0.2:1.2;
It's going to be normal now.
The text was updated successfully, but these errors were encountered: