Multivariate forward stepwise regression evluated by multivariate BIC
matrix of expression data (g genes x n samples), or ExpressionSet, or EList returned by voom() from the limma package
specifies baseline variables for the linear (mixed) model. Must only specify covariates, since the rows of exprObj are automatically used as a response. e.g.: ~ a + b + (1|c)
Formulas with only fixed effects also work, and lmFit()
followed by contrasts.fit()
are run.
data.frame with columns corresponding to formula
array of variable names to be considered in the regression. If variable should be considered as random effect, use '(1|A)'.
multivariate criterion ('AIC', 'BIC') or summing score assuming independence of reponses ('sum AIC', 'sum BIC')
Shrink covariance estimates to be positive definite. Using "var_equal" assumes all variance on the diagonal are equal. This method is the fastest because it is linear time. Using "var_unequal" allows each response to have its own variance term, however this method is quadratic time. Using "none" does not apply shrinkge, but is only valid when there are very few responses
"edf": effective degrees of freedom. "countLevels" count number of levels in each random effect. "lme4" number of variance compinents, as used by lme4. See description in nparam
stop interating of the model improvement is less than deltaCutoff. default is 5
use PCA to transform variables
Default TRUE. Print messages
additional arguements passed to logDet
list with formula of final model, and trace of iterations during model selection
Y = with(iris, rbind(Sepal.Width, Sepal.Length))
# fit forward stepwise regression starting with model: ~1.
bestModel = mvForwardStepwise( Y, ~ 1, data=iris, variables=colnames(iris)[3:5])
#> Base model: ~ 1
#>
evaluating: + Petal.Length
#>
evaluating: + Petal.Width
#>
evaluating: + Species
#>
#> Best model delta: -292.3
#> Add variable to model: Petal.Length
#> Base model: ~ 1 + Petal.Length
#>
evaluating: + Petal.Width
#>
evaluating: + Species
#>
#> Best model delta: -106.7
#> Add variable to model: Species
#> Base model: ~ 1 + Petal.Length + Species
#>
evaluating: + Petal.Width
#>
#> Best model delta: -8.1
#> Add variable to model: Petal.Width
bestModel
#> Multivariate IC forward stepwise regression
#>
#> Samples: 150
#> Responses: 2
#> Shrink method: EB
#> Criterion: BIC
#> Iterations: 3
#>
#> Best model: ~ 1 + Petal.Length + Species + Petal.Width
#>