Description Usage Arguments Value See Also
##Generic for cv.glmnet ## ##Accepts formula arguments ##
1 2 3 4 |
x |
formula ## |
y |
data.frame or environment in which |
... |
arguments passed to cv.glmnet ## |
sca |
SingleCellAssay object |
comparison |
character naming a column in |
min.freq |
minimum frequency for a gene to be considered in the classifier |
predictor |
character vector naming some combination of 'continuous', 'dichotomous' or 'interaction'. See details. |
pen.scale.interaction |
multiply the l1 penalty by this factor if interactions are included |
precenter |
should the gene predictors be centered? Recommended if there are interactions present to reduce co-linearity of the interaction with the marginal term. |
prescale |
should the gene predictors be scaled to have unit variance? |
addn |
character vector, giving additional columns of design, interpreted in the context of cData(sca) |
addn.penalty |
an optional numeric giving the relative scale of the penalty for add |
user.mm |
a function to be applied to exprs(sca) instead of the defaults given by |
alpha |
elasticnet penalty parameter. Default =.9. |
only.mm |
Should only the model matrix be returned, rather than actually calling cv.glmnet? |
... |
additional arguments to cv.glmnet. |
see cv.glmnet Run a multinomial lasso on a SingleCellAssay object to predict group membership
This function generates a design matrix based on the expression values in sca
and calls cv.glmnet
to try to classify a group named by comparison
, which keys a column in the cData
of sca
The design matrix is generated according to the option predictor
. If predictor
vector includes the term 'dichotomous', then each gene is treated as binary indicators. If the term 'continuous' is included, then the zero-inflated (continuous) value for the gene is used. If both 'continuous' and 'dichotomous' are included, then the both values for the gene are used, however the continuous values are centered about their conditional mean using the function xform
. If 'interaction' is included, then all the terms are crossed with each other to generate pairwise interactions.
list with components 'cv.fit' giving the output from cv.glmnet, 'mm' giving the model matrix, 'response' giving the response vector and 'sca' containing the 'sca' passed as input to the function
glmMisclass, getNZdesign, doGLMnet, cv.glmnet
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.