cgeniepy.ecology ================ .. py:module:: cgeniepy.ecology Classes ------- .. autoapisummary:: cgeniepy.ecology.EcoModel Module Contents --------------- .. py:class:: EcoModel(*args, **kwargs) Bases: :py:obj:`cgeniepy.model.GenieModel` EcoModel is an subclass of GenieModel, as EcoGENIE to cGENIE It facilitates the access of ecophysiological parameters and plankton variables Initialise a EcoModel object with a path to cGENIE output directory Example ----------- >>> from cgeniepy.ecology import EcoModel >>> model = EcoModel("path_to_GENIE_output") .. py:attribute:: eco_varlist .. py:attribute:: plank_n .. py:attribute:: phyto_indices .. py:attribute:: zoo_indices .. py:attribute:: mixo_indices .. py:attribute:: phyto_n .. py:attribute:: zoo_n .. py:attribute:: mixo_n .. py:method:: eco_pars() Get all the ecophysiological parameters used in the model :return: a pandas DataFrame object .. py:method:: get_pft(pft_index, prefix='Plankton', element='C') a variant of GenieModel's `get_var`, to select plankton functional type :param pft_index: the index of plankton functional type :param prefix: 'Plankton' or 'Export' :param element: 'C', 'Fe', 'P', 'Si', 'N' :return: a GenieArray object Example ---------------------------------------- >>> from cgeniepy.ecology import EcoModel >>> ### initialise a model object >>> model = EcoModel("path_to_GENIE_output") >>> ### get PFT-1 carbon biomass data >>> model.get_pft(1, "Plankton", "C") >>> ### get a list of PFT carbon biomass data >>> model.get_pft([1, 2, 3], "Plankton", "C") >>> ### get all phytoplankton carbon biomass data >>> model.get_pft('phyto', "Plankton", "C") >>> ### get all zooplankton carbon biomass data >>> model.get_pft('zoo', "Plankton", "C") >>> ### get all plankton carbon biomass data >>> model.get_pft('all', "Plankton", "C")