Compute skewness and kurtosis statistics
This uses the S+ version directly.
skewness(x, na.rm = FALSE, method = "fisher") kurtosis(x, na.rm = FALSE, method = "fisher")
x |
Any numerical object. Missing values |
na.rm |
Logical flag: if na.rm=TRUE, missing values are removed from x
before doing the computations. If |
method |
Character string specifying the computation method. The two
possible values are |
The moment
forms are based on the definitions of skewness and kurtosis
for distributions; these forms should be used when resampling (bootstrap or
jackknife). The "fisher" forms correspond to the usual "unbiased" definition of
sample variance, though in the case of skewness and kurtosis exact unbiasedness
is not possible.
A single value of skewness or kurtotis.
If y = x - mean(x), then the "moment" method computes the skewness value as mean(y^3)/mean(y^2) ^1.5 and the kurtosis value as mean(y^4)/mean(y ^2)^2 - 3. To see the "fisher" calculations, print out the functions.
Splus
var
x <- runif(30) skewness(x) skewness(x, method="moment") kurtosis(x) kurtosis(x, method="moment")
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.