Description Usage Arguments Value References
View source: R/stein-shrinkage.r
This function finds the value for α \in [0,1] that empirically minimizes the average risk under a Stein loss function, which is given on page 1023 of Pang et al. (2009).
1 | risk_stein(N, K, var_feature, num_alphas = 101, t = -1)
|
N |
the sample size. |
K |
the number of classes. |
var_feature |
a vector of the sample variances for each dimension. |
num_alphas |
The number of values used to find the optimal amount of shrinkage. |
t |
a constant specified by the user that indicates the exponent to use with the variance estimator. By default, t = -1 as in Pang et al. See the paper for more details. |
list with
alpha
: the alpha that minimizes the average risk under a Stein
loss function. If the minimum is not unique, we randomly select an
alpha
from the minimizers.
risk
: the minimum average risk attained.
Pang, H., Tong, T., & Zhao, H. (2009). "Shrinkage-based Diagonal Discriminant Analysis and Its Applications in High-Dimensional Data," Biometrics, 65, 4, 1021-1029. https://onlinelibrary.wiley.com/doi/abs/10.1111/j.1541-0420.2009.01200.x
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.