| Statistics Toolbox | Search  Help Desk |
| skewness | Examples See Also |
Syntax
y = skewness(X)
Description
skewness(X) returns the sample skewness ofX. For vectors, skewness(x) is the skewness of the elements of x. For matrices, skewness(X) is a row vector containing the sample skewness of each column.
Skewness is a measure of the asymmetry of the data around the sample mean. If skewness is negative, the data are spread out more to the left of the mean than to the right. If skewness is positive, the data are spread out more to the right. The skewness of the normal distribution (or any perfectly symmetric distribution) is zero.
The skewness of a distribution is defined as:
Example
X = randn([5 4])
X =
1.1650 1.6961 -1.4462 -0.3600
0.6268 0.0591 -0.7012 -0.1356
0.0751 1.7971 1.2460 -1.3493
0.3516 0.2641 -0.6390 -1.2704
-0.6965 0.8717 0.5774 0.9846
y = skewness(X)
y =
-0.2933 0.0482 0.2735 0.4641
See Also
kurtosis, mean, moment, std, var