# HG changeset patch # User Ben Abbott # Date 1287225537 -14400 # Node ID 65b240770880f71260adc8e702379795256dc605 # Parent dcde7c5a1d293255d274d9b2808f5b974e022c08 Fix normal line and marker types for errorplots. diff -r dcde7c5a1d29 -r 65b240770880 scripts/ChangeLog --- a/scripts/ChangeLog Thu Oct 14 14:43:59 2010 -0400 +++ b/scripts/ChangeLog Sat Oct 16 14:38:57 2010 +0400 @@ -1,3 +1,8 @@ +2010-10-16 Ben Abbott + + * plot/private/__errplot__.m, plot/errorbar.m: Allow line and marker + types to be set. + 2010-10-14 John W. Eaton * special-matrix/rosser.m: New tests. diff -r dcde7c5a1d29 -r 65b240770880 scripts/plot/errorbar.m --- a/scripts/plot/errorbar.m Thu Oct 14 14:43:59 2010 -0400 +++ b/scripts/plot/errorbar.m Sat Oct 16 14:38:57 2010 +0400 @@ -52,8 +52,9 @@ ## If @var{fmt} is missing, yerrorbars ("~") plot style is assumed. ## ## If the @var{fmt} argument is supplied, it is interpreted as in -## normal plots. In addition the following plot styles are supported by -## errorbar: +## normal plots. In addition, @var{fmt} may include an errorbar style +## which must preceed the line and marker format. The following plot +## styles are supported by errorbar: ## ## @table @samp ## @item ~ @@ -154,7 +155,7 @@ %! err = x/100; %! y1 = sin (x); %! y2 = cos (x); -%! hg = errorbar (x, y1, err, err, "#", x, y2, err, err, "#~"); +%! hg = errorbar (x, y1, err, err, "#r", x, y2, err, err, "#~"); %!demo %! x = 0:0.5:2*pi; @@ -162,6 +163,5 @@ %! y1 = sin (x); %! y2 = cos (x); %! hg = errorbar (x, y1, err, err, err, err, "~>", ... -%! x, y2, err, err, err, err, "#~>"); -%! set (hg(2), "marker", "*") +%! x, y2, err, err, err, err, "#~>-*"); diff -r dcde7c5a1d29 -r 65b240770880 scripts/plot/private/__errplot__.m --- a/scripts/plot/private/__errplot__.m Thu Oct 14 14:43:59 2010 -0400 +++ b/scripts/plot/private/__errplot__.m Sat Oct 16 14:38:57 2010 +0400 @@ -34,6 +34,8 @@ [fmt, key] = __pltopt__ ("__errplot__", fstr); + fmt + [len, nplots] = size (varargin{1}); h = []; @@ -53,7 +55,7 @@ elseif (strcmp (fmt.errorstyle, "#~>")) ifmt = "boxxy"; else - ifmt = "~"; + ifmt = "yerr"; endif hg = hggroup ("parent", p);