Preprocessing

Functions for preparing your data for trac.

aggregate_to_level()

Aggregate data to a fixed level

tax_table_to_phylo()

Convert a tax table to a phylo object

phylo_to_A()

Convert from phylo to the A matrix used in trac. Note this is similar to the A used in rare, but with the column of all ones (for the root) removed

Main trac functionality

Functions for fitting trac, choosing tuning parameter, and making predictions

trac()

Perform tree-based aggregation

cv_trac()

Perform cross validation for tuning parameter selection

predict_trac()

Make predictions based on a trac fit

Plotting functions

Sparse log contrast functions

sparse_log_contrast()

Perform sparse log-contrast regression

cv_sparse_log_contrast()

Perform cross validation for tuning parameter selection for sparse log contrast

plot_trac_path()

Plot trac coefficient path

plot_cv_trac()

Make a plot of the output of cv_trac

An example data set

A gut microbiome data set used in vignette

sCD14

sCD14 data

Refitting functions

Functions for fitting unregularized versions subject to the sparsity constraints learned by trac or sparse log-contrast

refit_trac()

Refit subject to sparsity constraints

refit_sparse_log_contrast()

Refit subject to sparsity constraints