Change width of error bars

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Change width of error bars

vatko
Hi,

I am plotting a curve with error bars in the y direction, and the the bars are too wide. Is there any way to change their width ? So, it is not the 'linewidth' that I want to change but the length of the top of the 'T' of the errorbars.

 I have many datapoints on the curve, the points are quite close to each other and I should put an error bar on all of them. So because the error bars are too wide they all overlap, giving an ugly hairy curve. I don't mind personally, but I have to prepare a figure for a publication and it should look nice. I save the figure using print, in the eps format. Whatever the size I choose for the final figure, the error bars always have the same width and they always overlap...


by the way I'm using octave 3.4.2
thanks for your help
Reply | Threaded
Open this post in threaded view
|

Re: Change width of error bars

Ismael Diego Nunez-Riboni
> I am plotting a curve with error bars in the y direction, and the the bars
> are too wide.

Which function do you use to plot the errorbars?

To my experience, the way plots are printed to file under octave depends
a lot on your graphics backed... Ben suggested to me once to use:

graphics_toolkit fltk

which worked fine for me for pcolors... Try it, repeat your plot and
print it to file... If it does not work perhaps you can simply edit the
function you use to plot the errorbars to make the "hats" shorter?

Cheers, Ismael.



Is there any way to change their width ? So, it is not the

> 'linewidth' that I want to change but the length of the top of the 'T' of
> the errorbars.
>
>   I have many datapoints on the curve, the points are quite close to each
> other and I should put an error bar on all of them. So because the error
> bars are too wide they all overlap, giving an ugly hairy curve. I don't mind
> personally, but I have to prepare a figure for a publication and it should
> look nice. I save the figure using print, in the eps format. Whatever the
> size I choose for the final figure, the error bars always have the same
> width and they always overlap...
>
>
> by the way I'm using octave 3.4.2
> thanks for your help
>
> --
> View this message in context: http://octave.1599824.n4.nabble.com/Change-width-of-error-bars-tp4412337p4412337.html
> Sent from the Octave - General mailing list archive at Nabble.com.
> _______________________________________________
> Help-octave mailing list
> [hidden email]
> https://mailman.cae.wisc.edu/listinfo/help-octave

_______________________________________________
Help-octave mailing list
[hidden email]
https://mailman.cae.wisc.edu/listinfo/help-octave
Reply | Threaded
Open this post in threaded view
|

Re: Change width of error bars

bpabbott
Administrator
In reply to this post by vatko

On Feb 22, 2012, at 7:35 PM, vatko wrote:

> Hi,
>
> I am plotting a curve with error bars in the y direction, and the the bars
> are too wide. Is there any way to change their width ? So, it is not the
> 'linewidth' that I want to change but the length of the top of the 'T' of
> the errorbars.
>
> I have many datapoints on the curve, the points are quite close to each
> other and I should put an error bar on all of them. So because the error
> bars are too wide they all overlap, giving an ugly hairy curve. I don't mind
> personally, but I have to prepare a figure for a publication and it should
> look nice. I save the figure using print, in the eps format. Whatever the
> size I choose for the final figure, the error bars always have the same
> width and they always overlap...
>
>
> by the way I'm using octave 3.4.2
> thanks for your help

There isn't a good / convenient way to do this with the current  version of octave.

It is possible to add a property to the error bar handle that sets the width of the bars. If you like this idea, please open a "feature request" in the bug tracker.

        https://savannah.gnu.org/bugs/?group=octave

If you're inclined to modify the sources to do this,

        (1) scripts/plot/errorbar.m: Needs to have its doc-string modified.
        (2) scripts/plot/private/__errplot__.m: Is where the changes need to be made.

Ben

_______________________________________________
Help-octave mailing list
[hidden email]
https://mailman.cae.wisc.edu/listinfo/help-octave