Warning
This site has been replaced by the new QIIME 2 “amplicon distribution” documentation, as of the 2025.4 release of QIIME 2. You can still access the content from the “old docs” here for the QIIME 2 2024.10 and earlier releases, but we recommend that you transition to the new documentation at https://amplicon-docs.qiime2.org. Content on this site is no longer updated and may be out of date.
Are you looking for:
the QIIME 2 homepage? That’s https://qiime2.org.
learning resources for microbiome marker gene (i.e., amplicon) analysis? See the QIIME 2 amplicon distribution documentation.
learning resources for microbiome metagenome analysis? See the MOSHPIT documentation.
installation instructions, plugins, books, videos, workshops, or resources? See the QIIME 2 Library.
general help? See the QIIME 2 Forum.
Old content beyond this point… 👴👵
mann-whitney-u: Mann-Whitney U Test¶
Citations |
|
---|
Docstring:
Usage: qiime stats mann-whitney-u [OPTIONS] Inputs: --i-distribution ARTIFACT Dist1D[Unordered | Ordered, Independent] [required] --i-against-each ARTIFACT Dist1D[Unordered | Ordered, Matched | Independent] [optional] Parameters: --p-compare TEXT Choices('reference', 'all-pairwise') The comparison that will be used to analyze the input `distribution`. Either "reference" or "all-pairwise" must be selected. The "reference" comparison defines Group A as the reference/control provided to `reference-group` (sourced from either `reference_column` or `control_column`), and Group B as all other groups. The "all-pairwise" comparison compares all groups to all other groups. If `against-each` is used, this will define Group B. [required] --p-reference-group TEXT If "reference" is the selected comparison, this is the column that will be used to compare all other groups against. [optional] --p-alternative TEXT Choices('two-sided', 'greater', 'less') The "two-sided" alternative hypothesis is that the median of Group A does not equal the median of Group B. The "greater" alternative hypothesis is that the median of group A is greater than the median of Group B. The "less" alternative hypothesis is that the median of group A is less than the median of Group B. [default: 'two-sided'] --p-p-val-approx TEXT Choices('auto', 'exact', 'asymptotic') "exact" will calculate an exact p-value for distributions, "asymptotic" will use a normal distribution, and "auto" will use either "exact" when one of the groups has less than 8 observations and there are no ties, otherwise "asymptotic". [default: 'auto'] Outputs: --o-stats ARTIFACT StatsTable[Pairwise] The Mann-Whitney U table for either the "reference" or "all-pairwise" comparison. [required] Miscellaneous: --output-dir PATH Output unspecified results to a directory --verbose / --quiet Display verbose output to stdout and/or stderr during execution of this action. Or silence output if execution is successful (silence is golden). --example-data PATH Write example data and exit. --citations Show citations and exit. --use-cache DIRECTORY Specify the cache to be used for the intermediate work of this action. If not provided, the default cache under $TMP/qiime2/will be used. IMPORTANT FOR HPC USERS: If you are on an HPC system and are using parallel execution it is important to set this to a location that is globally accessible to all nodes in the cluster. --help Show this message and exit. Examples: # ### example: mann whitney pairwise qiime stats mann-whitney-u \ --i-distribution refdist.qza \ --p-compare all-pairwise \ --i-against-each timedist.qza \ --p-p-val-approx asymptotic \ --o-stats stats.qza
Import:
from qiime2.plugins.stats.methods import mann_whitney_u
Docstring:
Mann-Whitney U Test Parameters ---------- distribution : Dist1D[Unordered | Ordered, Independent] compare : Str % Choices('reference', 'all-pairwise') The comparison that will be used to analyze the input `distribution`. Either "reference" or "all-pairwise" must be selected. The "reference" comparison defines Group A as the reference/control provided to `reference_group` (sourced from either `reference_column` or `control_column`), and Group B as all other groups. The "all-pairwise" comparison compares all groups to all other groups. If `against_each` is used, this will define Group B. reference_group : Str, optional If "reference" is the selected comparison, this is the column that will be used to compare all other groups against. against_each : Dist1D[Unordered | Ordered, Matched | Independent], optional alternative : Str % Choices('two-sided', 'greater', 'less'), optional The "two-sided" alternative hypothesis is that the median of Group A does not equal the median of Group B. The "greater" alternative hypothesis is that the median of group A is greater than the median of Group B. The "less" alternative hypothesis is that the median of group A is less than the median of Group B. p_val_approx : Str % Choices('auto', 'exact', 'asymptotic'), optional "exact" will calculate an exact p-value for distributions, "asymptotic" will use a normal distribution, and "auto" will use either "exact" when one of the groups has less than 8 observations and there are no ties, otherwise "asymptotic". Returns ------- stats : StatsTable[Pairwise] The Mann-Whitney U table for either the "reference" or "all-pairwise" comparison.