lmpy.data_wrangling.matrix.match_species_list_wrangler

Module containing data wranglers for matching a matrix to a species list.

Module Contents

Classes

MatchSpeciesListMatrixWrangler

Constructor for MatchSpeciesListMatrixWrangler class.

class lmpy.data_wrangling.matrix.match_species_list_wrangler.MatchSpeciesListMatrixWrangler(species_list, species_axis, **params)[source]

Bases: lmpy.data_wrangling.matrix.base._MatrixDataWrangler

Constructor for MatchSpeciesListMatrixWrangler class.

Parameters
  • species_list (SpeciesList or str) – A species list object or file path.

  • species_axis (int) – The matrix axis with species names to match.

  • **params (dict) – Keyword parameters to pass to _MatrixDataWrangler.

name = MatchSpeciesListMatrixWrangler[source]
version = 1.0[source]
wrangle_matrix(matrix)[source]

Wrangle a matrix.

Parameters

matrix (Matrix) – A matrix to wrangle.

Returns

The matrix subset to species list entries.

Return type

Matrix