comparison scripts/plot/pie.m @ 11341:3c7ba1e3dc21

Add missing option slice for pie and pie3
author Kai Habel <kai.habel@gmx.de>
date Fri, 10 Dec 2010 19:53:06 +0100
parents 4f399d91eb32
children fd0a3ac60b0e
comparison
equal deleted inserted replaced
11340:ef65ebb325e9 11341:3c7ba1e3dc21
15 ## You should have received a copy of the GNU General Public License 15 ## You should have received a copy of the GNU General Public License
16 ## along with Octave; see the file COPYING. If not, see 16 ## along with Octave; see the file COPYING. If not, see
17 ## <http://www.gnu.org/licenses/>. 17 ## <http://www.gnu.org/licenses/>.
18 18
19 ## -*- texinfo -*- 19 ## -*- texinfo -*-
20 ## @deftypefn {Function File} {} pie (@var{y}) 20 ## @deftypefn {Function File} {} pie (@var{x})
21 ## @deftypefnx {Function File} {} pie (@var{y}, @var{explode}) 21 ## @deftypefnx {Function File} {} pie (@var{x}, @var{explode})
22 ## @deftypefnx {Function File} {} pie (@dots{}, @var{labels}) 22 ## @deftypefnx {Function File} {} pie (@dots{}, @var{labels})
23 ## @deftypefnx {Function File} {} pie (@var{h}, @dots{}); 23 ## @deftypefnx {Function File} {} pie (@var{h}, @dots{});
24 ## @deftypefnx {Function File} {@var{h} =} pie (@dots{}); 24 ## @deftypefnx {Function File} {@var{h} =} pie (@dots{});
25 ## Produce a pie chart. 25 ## Produce a pie chart.
26 ## 26 ##
71 71
72 %!demo 72 %!demo
73 %! pie ([3, 2, 1], [0, 0, 1], {"Cheddar", "Swiss", "Camembert"}); 73 %! pie ([3, 2, 1], [0, 0, 1], {"Cheddar", "Swiss", "Camembert"});
74 %! colormap([1,0,0;0,1,0;0,0,1;1,1,0;1,0,1;0,1,1]); 74 %! colormap([1,0,0;0,1,0;0,0,1;1,1,0;1,0,1;0,1,1]);
75 %! axis ([-2,2,-2,2]); 75 %! axis ([-2,2,-2,2]);
76
77 %!demo
78 %! pie ([0.17, 0.34, 0.41], {"Cheddar", "Swiss", "Camembert"});
79 %! colormap([1,0,0;0,1,0;0,0,1;1,1,0;1,0,1;0,1,1]);
80 %! axis ([-2,2,-2,2]);
81 %! title ("missing slice");