metalonda {MetaLonDA} | R Documentation |
Metagenomic Longitudinal Differential Abundance Analysis for one feature
Description
Find significant time intervals of the one feature
Usage
metalonda(
Count,
Time,
Group,
ID,
n.perm = 500,
fit.method = "nbinomial",
points,
text = 0,
parall = FALSE,
pvalue.threshold = 0.05,
adjust.method = "BH",
time.unit = "days",
ylabel = "Normalized Count",
col = c("blue", "firebrick"),
prefix = "Test"
)
Arguments
Count |
matrix has the number of reads that mapped to each feature in each sample. |
Time |
vector of the time label of each sample. |
Group |
vector of the group label of each sample. |
ID |
vector of the subject ID label of each sample. |
n.perm |
number of permutations. |
fit.method |
fitting method (nbinomial, lowess). |
points |
points at which the prediction should happen. |
text |
Feature's name. |
parall |
boolean to indicate whether to use multicore. |
pvalue.threshold |
p-value threshold cutoff for identifing significant time intervals. |
adjust.method |
multiple testing correction method. |
time.unit |
time unit used in the Time vector (hours, days, weeks, months, etc.) |
ylabel |
text to be shown on the y-axis of all generated figures (default: "Normalized Count") |
col |
two color to be used for the two groups (eg., c("red", "blue")). |
prefix |
prefix to be used to create directory for the analysis results |
Value
returns a list of the significant time intervals for the tested feature.
References
Ahmed Metwally (ametwall@stanford.edu)
Examples
data(metalonda_test_data)
n.sample = 5
n.timepoints = 10
n.group = 2
Group = factor(c(rep(0, n.sample*n.timepoints), rep(1,n.sample*n.timepoints)))
Time = rep(rep(1:n.timepoints, times = n.sample), 2)
ID = factor(rep(1:(2*n.sample), each = n.timepoints))
points = seq(1, 10, length.out = 10)
## Not run:
output.nbinomial = metalonda(Count = metalonda_test_data[1,], Time = Time, Group = Group,
ID = ID, fit.method = "nbinomial", n.perm = 10, points = points,
text = rownames(metalonda_test_data)[1], parall = FALSE, pvalue.threshold = 0.05,
adjust.method = "BH", time.unit = "hours", ylabel = "Normalized Count", col = c("black", "green"))
## End(Not run)