Description Usage Arguments Details Value Examples
View source: R/fridge_function.R View source: R/fridge_functions.R
Function for calculating the fridge-ridge tuning parameter and prediction, with plot of MSE curve
1 |
X |
Matrix with covariates of dimension n x p |
y |
Vector of outcomes of length n |
x0 |
Vector of focus covariate of length p |
plug.in |
Character specifying the plug.in estimate, possibly 'OLS' (ordinary least squares) and 'RLO0CV' (ridge with leave-one-out cross-validation). The OLS option can only be used for p smaller than n. |
plot.curve |
Logical. Should the MSE curve and minimum value be ploted? |
The minimization routine is carried out with several different start values ranging from 1 to 10^7. If plot.curve = TRUE, the global minimum is ploted.
Result, a list with the following
fridge.tuning |
Numerical, the fridge tuning parameter |
loocv.tuning |
Numerical, the leave-one-out cross-validation tuning parameter |
fridge.pred |
Numerical, the fridge prediction |
loocv.pred |
Numerical, the leave-one-out cross-validation prediction |
1 | fridge()
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.