DA_mixMC: DA_mixMC

View source: R/DA_mixMC.R

DA_mixMCR Documentation



Fast run for mixMC sPLS-DA method for biomarker identification. It performs a CLR transformation on the 'counts + pseudo_counts' values. Then the sPLS-DA is tuned through a leave-one-out cross validation procedure.


  pseudo_count = 1,
  assay_name = "counts",
  contrast = NULL,
  ID_variable = NULL,
  verbose = TRUE



a phyloseq or TreeSummarizedExperiment object.


a positive numeric value for the pseudo-count to be added. Default is 1.


the name of the assay to extract from the TreeSummarizedExperiment object (default assayName = "counts"). Not used if the input object is a phyloseq.


character vector with exactly, three elements: a string indicating the name of factor whose levels are the conditions to be compared, the name of the level of interest, and the name of the other level.


a character string indicating the name of the variable name corresponding to the repeated measures units (e.g., the subject ID).


an optional logical value. If TRUE, information about the steps of the algorithm is printed. Default verbose = TRUE.


A list object containing the matrix of p-values 'pValMat', a matrix of summary statistics for each tag 'statInfo', and a suggested 'name' of the final object considering the parameters passed to the function. mixMC does not produce p-values. The frequency and the importance values are produced instead. The frequency indicates the stability of the features across the folds of the cross validation. The importance indicates the magnitude of the discrimination for the features and their direction. Hence, 'pValMat' matrix is filled with 1 - frequency values which are not p-values. To find discriminant features a threshold on this statistic can be used (liberal < 1, < 0.5, < 0.1 conservative).

See Also

splsda, perf, tune.splsda.


# Create a very simple phyloseq object
counts <- matrix(rnbinom(n = 60, size = 3, prob = 0.5), nrow = 10, ncol = 6)
metadata <- data.frame("Sample" = c("S1", "S2", "S3", "S4", "S5", "S6"),
                       "group" = as.factor(c("A", "A", "A", "B", "B", "B")))
ps <- phyloseq::phyloseq(phyloseq::otu_table(counts, taxa_are_rows = TRUE),
# Differential abundance
DA_mixMC(object = ps, pseudo_count = 1, contrast = c("group", "B", "A"),
    verbose = FALSE)

mcalgaro93/benchdamic documentation built on March 10, 2024, 10:40 p.m.