skbio.stats.gradient.GradientANOVA#
- class skbio.stats.gradient.GradientANOVA(coords, prop_expl, metadata_map, trajectory_categories=None, sort_category=None, axes=3, weighted=False)[source]#
Base class for the Trajectory algorithms.
- Parameters:
- coordspandas.DataFrame
The coordinates for each sample id
- prop_explarray like
The numpy 1-D array with the proportion explained by each axis in coords
- metadata_mappandas.DataFrame
The metadata map, indexed by sample ids and columns are metadata categories
- trajectory_categorieslist of str, optional
A list of metadata categories to use to create the trajectories. If None is passed, the trajectories for all metadata categories are computed. Default: None, compute all of them
- sort_categorystr, optional
The metadata category to use to sort the trajectories. Default: None
- axesint, optional
The number of axes to account while doing the trajectory specific calculations. Pass 0 to compute all of them. Default: 3
- weightedbool, optional
If true, the output is weighted by the space between samples in the sort_category column
- Raises:
- ValueError
If any category of trajectory_categories is not present in metadata_map If sort_category is not present in metadata_map If axes is not between 0 and the maximum number of axes available If weighted is True and no sort_category is provided If weighted is True and the values under sort_category are not numerical If coords and metadata_map does not have samples in common
Methods
Compute the trajectories for each group and category and run ANOVA.
Special methods (inherited)
__eq__
(value, /)Return self==value.
__ge__
(value, /)Return self>=value.
__getstate__
(/)Helper for pickle.
__gt__
(value, /)Return self>value.
__hash__
(/)Return hash(self).
__le__
(value, /)Return self<=value.
__lt__
(value, /)Return self<value.
__ne__
(value, /)Return self!=value.
__str__
(/)Return str(self).
Details