ko.glm {kosel} | R Documentation |
Statistics of the knockoffs procedure for glmnet regression models.
Description
Returns the vector of statistics W of the revisited knockoffs procedure for regressions available in the R package glmnet
. Most of the parameters come from glmnet()
. See glmnet
documentation for more details.
Usage
ko.glm(x, y, family = "gaussian", alpha = 1,
type.gaussian = ifelse(nvars < 500, "covariance", "naive"),
type.logistic = "Newton", type.multinomial = "ungrouped",
nVal = 50, random = FALSE)
Arguments
x |
Input matrix, of dimension nobs x nvars; each row is an observation vector. Can be in sparse matrix format (inherit from class " |
y |
Response variable. Quantitative for |
family |
Response type: "gaussian","binomial","poisson","multinomial","cox". Not available for "mgaussian". |
alpha |
The elasticnet mixing parameter, with 0 <= |
type.gaussian |
See |
type.logistic |
See |
type.multinomial |
See |
nVal |
Length of lambda sequence - default is 50. |
random |
If |
Value
A vector of dimension nvars corresponding to the statistics W.
See Also
Examples
# see ko.sel