Mercurial > hg > octave-nkf
comparison scripts/plot/slice.m @ 14247:c4fa5e0b6193
test: Make surface demos reproducible by setting colormap to default at start of demo.
* bicubic.m, interp2.m, interpn.m, griddata.m, image.m, axis.m, clabel.m,
colorbar.m, contour.m, contourf.m, cylinder.m, ezcontour.m, ezcontourf.m,
ezmesh.m, ezmeshc.m, ezsurf.m, ezsurfc.m, hold.m, pcolor.m, plotyy.m,
quiver3.m, ribbon.m, shading.m, slice.m, sombrero.m, surf.m, surfc.m,
surfnorm.m, trisurf.m: Set colormap to default at start of demos to
make them reproducible.
author | Rik <octave@nomad.inbox5.com> |
---|---|
date | Sun, 22 Jan 2012 10:02:27 -0800 |
parents | 11949c9795a0 |
children | 5d3a684236b0 |
comparison
equal
deleted
inserted
replaced
14246:8b220af26cfb | 14247:c4fa5e0b6193 |
---|---|
181 endfunction | 181 endfunction |
182 | 182 |
183 | 183 |
184 %!demo | 184 %!demo |
185 %! clf; | 185 %! clf; |
186 %! colormap ('default'); | |
186 %! [x, y, z] = meshgrid (linspace (-8, 8, 32)); | 187 %! [x, y, z] = meshgrid (linspace (-8, 8, 32)); |
187 %! v = sin (sqrt (x.^2 + y.^2 + z.^2)) ./ (sqrt (x.^2 + y.^2 + z.^2)); | 188 %! v = sin (sqrt (x.^2 + y.^2 + z.^2)) ./ (sqrt (x.^2 + y.^2 + z.^2)); |
188 %! slice (x, y, z, v, [], 0, []); | 189 %! slice (x, y, z, v, [], 0, []); |
189 | 190 |
190 %!demo | 191 %!demo |
191 %! clf; | 192 %! clf; |
193 %! colormap ('default'); | |
192 %! [x, y, z] = meshgrid (linspace (-8, 8, 32)); | 194 %! [x, y, z] = meshgrid (linspace (-8, 8, 32)); |
193 %! v = sin (sqrt (x.^2 + y.^2 + z.^2)) ./ (sqrt (x.^2 + y.^2 + z.^2)); | 195 %! v = sin (sqrt (x.^2 + y.^2 + z.^2)) ./ (sqrt (x.^2 + y.^2 + z.^2)); |
194 %! [xi, yi] = meshgrid (linspace (-7, 7)); | 196 %! [xi, yi] = meshgrid (linspace (-7, 7)); |
195 %! zi = xi + yi; | 197 %! zi = xi + yi; |
196 %! slice (x, y, z, v, xi, yi, zi); | 198 %! slice (x, y, z, v, xi, yi, zi); |