Mercurial > hg > octave-lyh
comparison scripts/plot/errorbar.m @ 14092:22c50cbad2ce stable
Add clf() to all plot demos.
* axis.m, compass.m, contour3.m, contourf.m, cylinder.m, ellipsoid.m,
errorbar.m, ezcontour.m, ezcontourf.m, ezmesh.m, ezmeshc.m, ezplot.m,
ezplot3.m, ezpolar.m, ezsurf.m, ezsurfc.m, feather.m, fplot.m,
loglogerr.m, pcolor.m, pie.m, pie3.m, plot3.m, plotmatrix.m,
quiver.m, quiver3.m, refreshdata.m, ribbon.m, rose.m, scatter3.m,
semilogx.m, semilogxerr.m, semilogy.m, semilogyerr.m, shading.m,
sombrero.m, stairs.m, stem.m, stem3.m, surf.m, surfc.m, surfl.m,
surfnorm.m, trimesh.m, triplot.m, trisurf.m, uimenu.m:
Add clf() to the beginning of each demo to ensure pre-existing graphics
objects don't interfere with the demo.
author | Ben Abbott <bpabbott@mac.com> |
---|---|
date | Wed, 21 Dec 2011 21:19:48 -0500 |
parents | c792872f8942 |
children | 72c96de7a403 |
comparison
equal
deleted
inserted
replaced
14091:c3ea07298af4 | 14092:22c50cbad2ce |
---|---|
136 | 136 |
137 endfunction | 137 endfunction |
138 | 138 |
139 | 139 |
140 %!demo | 140 %!demo |
141 %! clf | |
141 %! rand_1x11_data1 = [0.82712, 0.50325, 0.35613, 0.77089, 0.20474, 0.69160, 0.30858, 0.88225, 0.35187, 0.14168, 0.54270]; | 142 %! rand_1x11_data1 = [0.82712, 0.50325, 0.35613, 0.77089, 0.20474, 0.69160, 0.30858, 0.88225, 0.35187, 0.14168, 0.54270]; |
142 %! rand_1x11_data2 = [0.506375, 0.330106, 0.017982, 0.859270, 0.140641, 0.327839, 0.275886, 0.162453, 0.807592, 0.318509, 0.921112]; | 143 %! rand_1x11_data2 = [0.506375, 0.330106, 0.017982, 0.859270, 0.140641, 0.327839, 0.275886, 0.162453, 0.807592, 0.318509, 0.921112]; |
143 %! errorbar (0:10, rand_1x11_data1, 0.25*rand_1x11_data2); | 144 %! errorbar (0:10, rand_1x11_data1, 0.25*rand_1x11_data2); |
144 | 145 |
145 %!demo | 146 %!demo |
147 %! clf | |
146 %! rand_1x11_data3 = [0.423650, 0.142331, 0.213195, 0.129301, 0.975891, 0.012872, 0.635327, 0.338829, 0.764997, 0.401798, 0.551850]; | 148 %! rand_1x11_data3 = [0.423650, 0.142331, 0.213195, 0.129301, 0.975891, 0.012872, 0.635327, 0.338829, 0.764997, 0.401798, 0.551850]; |
147 %! rand_1x11_data4 = [0.682566, 0.456342, 0.132390, 0.341292, 0.108633, 0.601553, 0.040455, 0.146665, 0.309187, 0.586291, 0.540149]; | 149 %! rand_1x11_data4 = [0.682566, 0.456342, 0.132390, 0.341292, 0.108633, 0.601553, 0.040455, 0.146665, 0.309187, 0.586291, 0.540149]; |
148 %! errorbar(0:10, rand_1x11_data3, rand_1x11_data4, ">"); | 150 %! errorbar(0:10, rand_1x11_data3, rand_1x11_data4, ">"); |
149 | 151 |
150 %!demo | 152 %!demo |
153 %! clf | |
151 %! x = 0:0.5:2*pi; | 154 %! x = 0:0.5:2*pi; |
152 %! err = x/100; | 155 %! err = x/100; |
153 %! y1 = sin (x); | 156 %! y1 = sin (x); |
154 %! y2 = cos (x); | 157 %! y2 = cos (x); |
155 %! hg = errorbar (x, y1, err, "~", x, y2, err, ">"); | 158 %! hg = errorbar (x, y1, err, "~", x, y2, err, ">"); |
156 | 159 |
157 %!demo | 160 %!demo |
161 %! clf | |
158 %! x = 0:0.5:2*pi; | 162 %! x = 0:0.5:2*pi; |
159 %! err = x/100; | 163 %! err = x/100; |
160 %! y1 = sin (x); | 164 %! y1 = sin (x); |
161 %! y2 = cos (x); | 165 %! y2 = cos (x); |
162 %! hg = errorbar (x, y1, err, err, "#r", x, y2, err, err, "#~"); | 166 %! hg = errorbar (x, y1, err, err, "#r", x, y2, err, err, "#~"); |
163 | 167 |
164 %!demo | 168 %!demo |
169 %! clf | |
165 %! x = 0:0.5:2*pi; | 170 %! x = 0:0.5:2*pi; |
166 %! err = x/100; | 171 %! err = x/100; |
167 %! y1 = sin (x); | 172 %! y1 = sin (x); |
168 %! y2 = cos (x); | 173 %! y2 = cos (x); |
169 %! hg = errorbar (x, y1, err, err, err, err, "~>", ... | 174 %! hg = errorbar (x, y1, err, err, err, err, "~>", ... |