g | R Documentation |
Estimates the mean vector of a primary homoscedastic sequence of independent Gaussian observations under squared error loss. The optimal decision rule is estimated by directly minimizing an unbiased estimate of its risk.
g(x, s, rho = 0, K = 10, C = 5, tol = 1e-05, maxit = 100, verbose = FALSE)
x |
Gaussian sequence |
s |
standard deviation |
rho |
regularization parameter, closer to 0 means less regularization |
K |
number of grid points, in the interval [x_j - C s, x_j + C s], over which to search for the jth tuning parameter, where C is define below |
C |
the value of the constant C in the interval above |
tol |
error tolerance for convergence of the unbiased risk estimate |
maxit |
maximum number of allowable iterations |
verbose |
should the value of SURE be reported at each iteration |
t_hat |
values of tuning parameters t |
theta_hat |
estimated values of means of Gaussian sequence |
## generate data n = 250 set.seed(1) theta = rnorm(n) x = theta + rnorm(n) ## loss of MLE mean((theta - x)^2) ## loss of estimator incorporating side information mean((theta - g(x, 1)$theta_hat)^2)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.