| Statistics Toolbox | Search  Help Desk |
| cdf | Examples See Also |
Computes a chosen cumulative distribution function (cdf).
Syntax
P = cdf('name',X,A1,A2,A3)
Description
cdf is a utility routine allowing you to access all the cdfs in the Statistics Toolbox using the name of the distribution as a parameter.P = cdf('name',X,A1,A2,A3) returns a matrix of probabilities. name is a string containing the name of the distribution. X is a matrix of values, and A, A2, and A3 are matrices of distribution parameters. Depending on the distribution, some of the parameters may not be necessary.
The arguments X, A1, A2, and A3 must all be the same size except that scalar arguments function as constant matrices of the common size of the other arguments.
Examples
p = cdf('Normal',-2:2,0,1)
p =
0.0228 0.1587 0.5000 0.8413 0.9772
p = cdf('Poisson',0:5,1:6)
p =
0.3679 0.4060 0.4232 0.4335 0.4405 0.4457
See Also
icdf, mle, pdf, random