MATLAB Functions | Help Desk |
pie3
Three-dimensional pie chartpie3(X) pie3(X,Explode) h = pie3(...)
pie3(X)
draws a three-dimensional pie chart using the data in X
. Each element in X
is represented as a slice in the pie chart.
pie3(X,Explode)
specifies whether to offset a slice from the center of the pie chart. X(i,j)
is offset from the center of the pie chart if Explode(i,j)
is nonzero. Explode
must be the same size as X
.
h = pie(...)
returns a vector of handles to Patch, Surface, and Text graphics objects.
If sum(X) 1
, pie3
normalizes the X
values so that each slice has an area of Xi/sum(Xi), where Xi
is an element of X
. The normalized value specifies the fractional part of each pie slice. If sum(X) < 1
, pie3
does not normalize the elements of X
. pie3
draws a partial pie when sum(X) < 1
.
A slice in the pie chart is offset by setting the corresponding explode
element to 1
:
x = [1 3 0.5 2.5 2] explode = [0 1 0 0 0] pie3(x,explode)
pie