This function computes the cross-validation-optimal regression coefficients for lasso.

1 |

`X` |
matrix of observations. The rows of |

`y` |
vector of responses. The length of y must equal the number of rows of X |

`k` |
the number of splits in |

`use.Gram` |
When the number of variables is very large, you may not want LARS to precompute the Gram matrix. Default is |

`normalize` |
Should the columns of |

`intercept` |
Should an intercept be included? Default is |

We use the glmnet() function from the glmnet package to compute the fit. Note that in Kraemer et. al. (2009), we used the lars() function from the lars package, which is much slower than glmnet().

`lambda` |
vector of paramter values from which the optimal parameter is selected |

`cv` |
cross-validated error for all |

`lambda.opt` |
cross-validation optimal parameter |

`cv.lasso` |
cv error for the optimal model. |

`intercept` |
cross-validation optimal intercept. If |

`coefficients` |
cross-validation optimal regression coefficients, without intercept |

Nicole Kraemer

R. Tibshirani (1997) "Regression Shrinkage and Selection via the Lasso", Journal of the Royal Statistical Society B, 58 (1)

N. Kraemer, J. Schaefer, A.-L. Boulesteix (2009) "Regularized Estimation of Large-Scale Gene Regulatory Networks with Gaussian Graphical Models", BMC Bioinformatics, 10:384

http://www.biomedcentral.com/1471-2105/10/384/

1 2 3 4 5 |

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.