This functions calculates the first three moments as well as mean, standard deviation and skewness for a vector of observations with corresponding weights.
Usage
weighted.moments(x, w8 = NULL)
Arguments
x
a vector of observations.
w8
a vector of weights.
Value
fmreturns the first moment.
weighted.meanreturns the mean.
smreturns the second moment.
weighted.sdreturns the uncorrected (population) standard deviation.
wtd.sdreturns the sample-size corrected standard deviation estimate.
tmreturns the third moment.
w.skew.SASreturns the skewness estimate as implemented in SAS.
w.skew.Statareturns the skewness estimate as implemented in Stata.