fac: Selecting the optimal number of latent variables.

View source: R/fac.R

facR Documentation

Selecting the optimal number of latent variables.

Description

Select the optimal number of latent variables by varying the number of latent variables from fmin to fmax.

Usage

fac(Y, X, minq = 1, maxq = 2, epsilon = 0.01, plot.BIC = FALSE, printout = TRUE)

Arguments

Y

Expression data in samples by features format.

X

Design matrix from model.matrix function which defines how covariates are included into sBFAC.

minq

Minimum number of latent variables to be considered. Default is 1.

maxq

Maximum number of latent variables to be considered. Default is 2. fmax should be greater or equal to fmin.

epsilon

Assessing convergence.

plot.BIC

Plot BIC values for selecting the optimal number of latent variables.

printout

Print when the model have converged.

Details

Select the optimal number of latent variables by varying the number of latent variables from fmin to fmax.

Value

qopt

The optimal number of latent variables selected by BIC.

sig

Residual variability associated with each feature.

sig

Residual variability associated with each latent variable.

factors

Scores of observations on each latent variable.

loadings

Loadings of features on each latent variable.

coefficients

Regression coefficient for each covariate.

Author(s)

Gift Nyamundanda, Katie Eason, Pawan Poudel and Anguraj Sadanandam.

References

Nyamundanda et al (2015). A next generation tool enables identification of functional cancer subtypes with associated biological phenotypes.

Examples

## help(fac) 

syspremed/PhenMAP documentation built on April 2, 2022, 3:12 p.m.