This method implements the method of empirical variances as described in Gagnon-Bartsch, Jacob, and Speed (2013). This function is normally called from the function variance_adjust
, and is not normally intended for stand-alone use.
get_empirical_variances(sigma2, betahat, bin = 10,
rescaleconst = NULL)
Estimates of sigma^2
Estimates of beta
The bin size
The expected value of the average of the smallest bin - 1
of bin
independent chi-square random variables. This can be specified to save computational time (otherwise, it is calculated by simulation).
A vector of the empirical variances.
Removing Unwanted Variation from High Dimensional Data with Negative Controls. Gagnon-Bartsch, Jacob, and Speed, 2013. Available at: http://statistics.berkeley.edu/tech-reports/820.