View source: R/DNCI_multigroup.R
DNCI_multigroup | R Documentation |
This function is a wraper for DNCI.ses() function. Can be used with 2 group or more. Warning: if you are comparing groups of different size, use symmetrize = TRUE and repeat the computation N times.
DNCI_multigroup(
x,
grouping,
id = "no_name",
Nperm = 1000,
count = TRUE,
symmetrize = FALSE,
plotSIMPER = TRUE,
dataTYPE = "prab",
parallelComputing = FALSE
)
x |
Sample/Taxa matrix with sample in row and taxa in column |
grouping |
Grouping vector, ex : c(1,1,1,1,2,2,2,2,2) : 2 groups or more ex2 : c(1,1,1,1,1,2,2,2,2,3,3,3,3) |
id |
Name of the dataset, default = "no_name" |
Nperm |
Number of permutation, default = 1000, should be change to 100 for robustness analysis |
count |
Display the number of permutation done, can be usefull with very large or small matrix, default = TRUE |
symmetrize |
By random sampling of the largest groups, analyzed pairs of group are made even. Strong heterogeneity in group length can impact DNCI values. More information in function file and Vilmi et al. 2021. |
plotSIMPER |
Display the SIMPER, PerSIMPER and E index plots, default = TRUE |
dataTYPE |
Need to be set for presence/absence or abundance data ("count"), default = "prab" (presence_absence) |
parallelComputing |
Run PerSIMPER on half of the available cores/nodes |
Quantitative identification of the main assembly process. Pairwise analysis. This function is based on DNCI_ses (for 2 group analysis) and PerSIMPER function E index return(). The three distributions of E index (corresponding to the three hypothesis: niche, dispersal, niche+dispersal) are used to compute the DNCI index. If DNCI is significantly < 0 : dispersal || DNCI significantly > 0 : niche || DNCI +- CI ~~ 0 : dispersal+niche See Vilmi, Gibert et al. 2021 Ecography for DNCI computation and more information on process identification as well as example with Chinese and US river communities. More information in code and comments inside function file.
A <- DNCImper:::DNCI_multigroup(Matrix, Group)
#where Matrix is a presence/absence matrix with taxa in column and sample in row
#and Group is a vector with length() == number of rows/samples in Matrix, 2 groups, 1 pair
#
B <- DNCImper:::DNCI_multigroup(DNCImper::Matrix_4groups, DNCImper::Group4, Nperm = 100, count = FALSE, plotSIMPER = FALSE)
#In this example, four groups (so 6 pairs) are analysed, with 100 permutations, with no countdown and no plots
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.