fit_SparseDOSSA2: Fit SparseDOSSA 2 model to a microbiome abundance dataset

View source: R/SparseDOSSA2_fit.R

fit_SparseDOSSA2R Documentation

Fit SparseDOSSA 2 model to a microbiome abundance dataset

Description

fit_SparseDOSSA2 fits the SparseDOSSA 2 model (zero-inflated log normal marginals connected through Gaussian copula) to microbial abundances. It takes as input a feature-by-sample microbial count or relative abundance table and a penalization tuning parameter lambda to control the sparsity of feature-feature correlations. It then adopts a penalized expectation-maximization algorithm to provide estimations of the model parameters.

Usage

fit_SparseDOSSA2(data, lambda = 1, control = list())

Arguments

data

feature-by-sample matrix of abundances (proportions or counts)

lambda

positive penalization parameter for the sparsity of feature-feature correlations. Default to maxmum value 1, where features are assumed to be independent (no correlations, most sparse)

control

a named list of additional control parameters. See help page for control_fit

Value

a list, with the following components:

EM_fit

list of fitted parameters from the EM algorithm.

F_fit

fitted parameters for the joint distribution of per-feature prevalence, abundance, and variability parameters (for simulating new features)

depth_fit

fitted parameters for the read depth distribution. Only applicable to count data.

l_filtering

list of quality control filtering for sample and features.

Author(s)

Siyuan Ma, syma.research@gmail.com

Examples

data("Stool_subset")
fitted <- fit_SparseDOSSA2(data = Stool_subset)

biobakery/SparseDOSSA2 documentation built on March 30, 2024, 9:26 p.m.