analyticVar | R Documentation |
This model-free method to calculate analytically the standard error of the variance. It's based on the use of the appropriate h-statistic as an estimator, as default. It is offers a corrected version of the method described in Wonnapinij et al.. If instead the Wonnapinij et al. method shall be used, use method="Wonnapinij".
analyticVar(data, normal = FALSE, method = "hstatistic")
data |
The input data in the form of a vector. NA values are omitted. |
normal |
Parameter that indicates if the normal approximation should be used instead of the general formula from (Wilks, S. S. (1962).Mathematical Statistics). Default is FALSE. |
method |
What method to use for the estimation of the standard error of the variance. Accepted values are "hstatistic" (default) and "Wonnapinij". |
The analytically derived standard error of the variance of data
.
# size of the sample
n=50
#generate a random sample of size n from a normal distribution
data_ex=rnorm(n,0.5,0.1)
analyticVar(data)
mouseData=readHeteroplasmyData("HB")
mouseData1 = mouseData[which(!is.na(mouseData[,1])),1]
analyticVar(mouseData1,method="hstatistic")
# use the package data and load it to variable mouseData
mouseData=mousedataLE
# calculate the standard error of the variance for the LE oocyte sample #3
bootstrapVar(mouseData[,3])
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.