cdfplot
Display an empirical cumulative distribution function.
hCDF = cdfplot (x) plots an empirical cumulative
distribution function (CDF) of the observations in the data sample vector
x. x may be a row or column vector, and represents a random
sample of observations from some underlying distribution.
cdfplot plots F(x), the empirical (or sample) CDF versus the
observations in x. The empirical CDF, F(x), is defined as follows:
F(x) = (Number of observations <= x) / (Total number of observations)
for all values in the sample vector x. NaNs are ignored. hCDF is the handle of the empirical CDF curve (a handle hraphics ’line’ object).
[hCDF, stats] = cdfplot (x) also returns a structure
with the following fields as a statistical summary.
| STATS.min | minimum value of x | |
| STATS.max | maximum value of x | |
| STATS.mean | sample mean of x | |
| STATS.median | sample median (50th percentile) of x | |
| STATS.std | sample standard deviation of x |
Source Code: cdfplot
x = randn(100,1);
cdfplot (x);
|