kurtosis {kim} | R Documentation |
Kurtosis
Description
Calculate kurtosis of the sample using a formula for either the (1) biased estimator or (2) an unbiased estimator of the population kurtosis. Formulas were taken from DeCarlo (1997), doi:10.1037/1082-989X.2.3.292
Usage
kurtosis(vector = NULL, unbiased = TRUE)
Arguments
vector |
a numeric vector |
unbiased |
logical. If |
Value
a numeric value, i.e., kurtosis of the given vector
Examples
# calculate the unbiased estimator (e.g., kurtosis value that
# Excel 2016 will produce)
kim::kurtosis(c(1, 2, 3, 4, 5, 10))
# calculate the biased estimator (e.g., kurtosis value that
# R Package 'moments' will produce)
kim::kurtosis(c(1, 2, 3, 4, 5, 10), unbiased = FALSE)
# compare with kurtosis from 'moments' package
moments::kurtosis(c(1, 2, 3, 4, 5, 10))
[Package kim version 0.5.422 Index]