This function applies a variety of transformations to the read counts and
format the sample by feature table and meta data into a data list
that can be used as the input of tempted and svd_centralize.
For data that are not read counts, or data that are not microbiome data,
the user can apply their desired transformation to the data before formatting into list.
format_tempted(
featuretable,
timepoint,
subjectID,
threshold = 0.95,
pseudo = NULL,
transform = "clr"
)A length n list of matrices as the input of tempted and svd_centralize. Each matrix represents a subject, with columns representing samples from this subject, the first row representing the sampling time points, and the following rows representing the feature values.
A sample by feature matrix.
The time stamp of each sample, matched with the rows of featuretable.
The subject ID of each sample, matched with the rows of featuretable.
A threshold for feature filtering for microbiome data. Features with zero value percentage > threshold will be excluded. Default is 0.95.
A small number to add to all the counts before
normalizing into proportions and log transformation.
Default is 1/2 of the smallest non-zero value that is specific for each sample.
This pseudo count is added for transform=c("logcomp", "clr", "logit").
The transformation applied to the data.
"logcomp" for log of compositions.
"comp" for compositions.
"ast" for arcsine squared transformation.
"clr" for central log ratio transformation.
"lfb" for log 2 fold change over baseline (first time point) transformation.
"logit" for logit transformation.
"none" for no transformation.
Default transform="clr" is recommended for microbiome data.
For data that are already transformed, use transform="none".
Examples can be found in tempted.