bst.sel | R Documentation |
Function to determine the first q predictors in the boosting path, or perform (10-fold) cross-validation and determine the optimal set of parameters
bst.sel(x, y, q, type=c("firstq", "cv"), ...)
x |
Design matrix (without intercept). |
y |
Continuous response vector for linear regression |
q |
Maximum number of predictors that should be selected if |
type |
if |
... |
Further arguments to be passed to |
Function to determine the first q predictors in the boosting path, or perform (10-fold) cross-validation and determine the optimal set of parameters. This may be used for p-value calculation. See below.
Vector of selected predictors.
Zhu Wang
## Not run: x <- matrix(rnorm(100*100), nrow = 100, ncol = 100) y <- x[,1] * 2 + x[,2] * 2.5 + rnorm(100) sel <- bst.sel(x, y, q=10) library("hdi") fit.multi <- hdi(x, y, method = "multi.split", model.selector =bst.sel, args.model.selector=list(type="firstq", q=10)) fit.multi fit.multi$pval[1:10] ## the first 10 p-values fit.multi <- hdi(x, y, method = "multi.split", model.selector =bst.sel, args.model.selector=list(type="cv")) fit.multi fit.multi$pval[1:10] ## the first 10 p-values ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.