Metadata-Version: 2.1
Name: MetEvolSim
Version: 0.2.3
Summary: MetEvolSim (Metabolome Evolution Simulator) Python Package
Home-page: https://github.com/charlesrocabert/MetEvolSim
Author: Charles Rocabert, Gábor Boross, Balázs Papp
Author-email: 
License: GNU General Public License v3 (GPLv3)
Project-URL: Source, https://github.com/charlesrocabert/MetEvolSim
Description: <h1 align="center">MetEvolSim</h1>
        <p align="center">
            Python package dedicated to the evolution of metabolic concentrations
            <br/><br/>
            <a href="https://github.com/charlesrocabert/MetEvolSim/releases/latest"><img src="https://img.shields.io/badge/PyPI package- 0.2.0-orange.svg" /></a>&nbsp;<a href="https://www.gnu.org/licenses/gpl-3.0"><img src="https://img.shields.io/badge/license-GPL v3-blue.svg" /></a>&nbsp;
            <br/>
            <img src="./logos/metevolsim_logo.png" width=150>
        </p>
        
        -----------------
        
        <p align="justify">
        MetEvolSim is a Python package providing numerical tools to study the long-term evolution of metabolic concentrations.
        MetEvolSim takes as an input any <a href="http://sbml.org/Main_Page">SBML</a> metabolic network model, as soon as kinetic parameters and initial metabolic concentrations are specified, and a stable steady-state exists. Steady-state concentrations are computed thanks to <a href="http://copasi.org/">Copasi</a> software.
        </p>
        
        <p align="justify">
        MetEvolSim is being developed by Charles Rocabert, Gábor Boross and Balázs Papp.
        </p>
        
        <p align="center">
        <img src="./logos/BRC_logo.png" height="100px"></a>&nbsp;&nbsp;&nbsp;<img src="./logos/MTA_logo.png" height="100px"></a>
        </p>
        
        ## Table of contents
        - [Dependencies](#dependencies)
        - [Installation](#installation)
        - [First usage](#first_usage)
        - [Help](#help)
        - [Copyright](#copyright)
        - [License](#license)
        
        ## Dependencies <a name="dependencies"></a>
        - Python &ge; 3,
        - Numpy &ge; 1.15 (automatically installed when using pip),
        - Python-libsbml &ge; 5.17 (automatically installed when using pip),
        - pip &ge; 19.1 (optional).
        
        ## Installation <a name="installation"></a>
        &bullet; To install Copasi software, visit http://copasi.org/.
        
        &bullet; To install Python dependencies:
        ```shell
        pip install numpy python-libsbml
        ```
        
        &bullet; To install the current release of MetEvolSim:
        ```shell
        pip install MetEvolSim
        ```
        
        Alternatively, download the <a href="https://github.com/charlesrocabert/MetEvolSim/releases/latest">latest release</a> in the folder of your choice and unzip it. Then follow the instructions below:
        ```shell
        # Navigate to the MetEvolSim folder
        cd /path/to/MetEvolSim
        
        # Install metevolsim Python package
        python3 setup.py install
        ```
        
        ## First usage <a name="first_usage"></a>
        MetEvolSim takes as an input any <a href="http://sbml.org/Main_Page">SBML</a> metabolic network model, as soon as kinetic parameters and initial metabolic concentrations are specified, and a stable steady-state exists. MetEvolSim provides a class to manipulate SBML models: the class <code>Model</code>. It is also necessary to define an objective function (a list of reaction names and coefficients), and to provide the path of CopasiSE software.
        
        ```python
        # Import metevolsim package
        import MetEvolSim
        
        # Create an objective function
        target_fluxes = [['ATPase', 1.0], ['PDC', 1.0]]
        
        # Load the SBML metabolic model
        model = MetEvolSim.Model(sbml_filename='glycolysis.xml', objective_function=target_fluxes, copasi_path='/Applications/COPASI/CopasiSE')
        
        # Print some informations on the metabolic model
        print(model.get_number_of_species())
        print(model.get_WT_species_value('Glc'))
        
        # Get a kinetic parameter at random
        param = model.get_random_parameter()
        print(param)
        
        # Mutate this kinetic parameter with a log-scale mutation size 0.01
        model.random_parameter_mutation(param, sigma=0.01)
        
        # Compute wild-type and mutant steady-states
        model.compute_WT_steady_state()
        model.compute_mutant_steady_state()
        ```
        
        MetEvolSim allows two types of numerical analyses on a SBML metabolic model:
        - <strong>Evolution experiments</strong>, based on a Markov Chain Monte Carlo (MCMC) algorithm,
        - <strong>Sensitivity analysis</strong>, by exploring every kinetic parameters in a given range and recording associated fluxes and metabolic abundances changes.
        
        All numerical analyses output files are saved in a subfolder <code>output</code>, automatically created by MetEvolSim.
        
        ### Evolution experiments:
        Three types of evolution experiments are available:
        - <code>MUTATION_ACCUMULATION</code>: Run a mutation accumulation experiment by accepting all new mutations without any selection threshold,
        - <code>METABOLIC_SUM_SELECTION</code>: Run an evolution experiment by applying a stabilizing selection on the sum of metabolic abundances,
        - <code>TARGET_FLUXES_SELECTION</code>: Run an evolution experiment by applying a stabilizing selection on the objective function.
        
        ```python
        # Load a Markov Chain Monte Carlo (MCMC) instance
        mcmc = MetEvolSim.MCMC(sbml_filename='glycolysis.xml', objective_function=target_fluxes, total_iterations=10000, sigma=0.01, selection_scheme="MUTATION_ACCUMULATION", selection_threshold=1e-4, copasi_path='/Applications/COPASI/CopasiSE')
        
        # Initialize the MCMC instance 
        mcmc.initialize()
        
        # Compute the successive iterations and write output files
        stop_MCMC = False
        while not stop_MCMC:
            stop_mcmc = mcmc.iterate()
            mcmc.write_output_file()
            mcmc.write_statistics()
        ```
        
        ### Sensitivity analysis:
        ```python
        # Load a sensitivity analysis instance
        sa = MetEvolSim.SensitivityAnalysis(sbml_filename='glycolysis.xml', factor_range=1.0, factor_step=0.01, copasi_path='/Applications/COPASI/CopasiSE')
        
        # Initialize the sensitivity analysis instance 
        sa.initialize()
        
        # Perform the sensitivity analysis for each kinetic parameter
        stop_SA = False
        while not stop_SA:
            stop_SA = sa.explore_next_parameter()
        ```
        
        ## Help <a name="help"></a>
        To get some help on a MetEvolSim class or method, use the Python help function:
        ```python
        help(MetEvolSim.Model.set_species_initial_value)
        ```
        to obtain a quick description and the list of parameters and outputs:
        ```
        Help on function set_species_initial_value in module MetEvolSim:
        
        set_species_initial_value(self, species_id, value)
            Set the initial concentration of the species 'species_id' in the
            mutant model.
            
            Parameters
            ----------
            species_id: str
                    Species identifier (as defined in the SBML model).
            value: float >= 0.0
                    Species abundance.
                    
            Returns
            -------
            None
        (END)
        ```
        
        ## Copyright <a name="copyright"></a>
        Copyright &copy; 2018-2019 Charles Rocabert, Gábor Boross and Balázs Papp.
        All rights reserved.
        
        ## License <a name="license"></a>
        <p align="justify">
        This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
        </p>
        
        <p align="justify">
        This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
        </p>
        
        <p align="justify">
        You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
        </p>
        
Keywords: metabolism abundances evolution metabolic-network kinetic-model evolution-rate
Platform: UNKNOWN
Classifier: Development Status :: 4 - Beta
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: GNU General Public License v3 (GPLv3)
Classifier: Operating System :: OS Independent
Classifier: Intended Audience :: Science/Research
Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
Requires-Python: >=3
Description-Content-Type: text/markdown
