7.1.1.1.1.1.1. intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm package

7.1.1.1.1.1.1.1. Submodules

7.1.1.1.1.1.1.2. intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.analysis module

Analysis utility functions

@author Jonathan Karr, karr@mssm.edu @date 3/26/2016

intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.analysis.get_scale(units, compartmentId, volume, extracellularVolume)[source]

Get the scale for a unit

Parameters
  • units (str) – units

  • compartmentId (str) – compartment id

  • volume (float) – volume

  • extracellularVolume (float) – extracellular volume

Returns

scale

Return type

float

intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.analysis.get_y_data(model, speciesCounts, speciesCompartmentId)[source]
Parameters
  • model

  • speciesCompartmentId

Returns

species compartment yData

intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.analysis.plot(model, time=array([], dtype=float64), speciesCounts=None, volume=array([], dtype=float64), extracellularVolume=array([], dtype=float64), selectedSpeciesCompartments=[], yDatas={}, units='mM', fileName='')[source]

7.1.1.1.1.1.1.3. intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model module

Reads models specified in Excel into a Python object

@author Jonathan Karr, karr@mssm.edu @date 3/22/2016

class intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.Compartment(id='', name='', initialVolume=None, comments='')[source]

Bases: object

comments = ''[source]
id = ''[source]
index = None[source]
initialVolume = None[source]
name = ''[source]
class intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.Concentration(compartment='', value=None)[source]

Bases: object

compartment = ''[source]
value = None[source]
class intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.ExchangedSpecies(id='', reactionIndex=None)[source]

Bases: object

id = ''[source]
reactionIndex = None[source]
class intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.FbaSubmodel(*args, **kwargs)[source]

Bases: intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.Submodel

calcReactionBounds(timeStep=1)[source]
calcReactionFluxes(timeStep=1)[source]

calculate growth rate

cobraModel = None[source]
defaultFbaBound = 1000000000000000.0[source]
dryWeight = nan[source]
exchangeRateBounds = None[source]
exchangedSpecies = None[source]
growth = nan[source]
metabolismProductionReaction = None[source]
reactionFluxes = array([], dtype=float64)[source]
setupSimulation()[source]

setup reaction participant, enzyme counts matrices

solver = 'glpk'[source]
thermodynamicBounds = None[source]
updateGlobalCellState(model)[source]
updateLocalCellState(model)[source]
updateMetabolites(timeStep=1)[source]
class intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.Identifier(namespace='', id='')[source]

Bases: object

id = ''[source]
namespace = ''[source]
class intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.Model(submodels=None, compartments=None, species=None, reactions=None, parameters=None, references=None)[source]

Bases: object

calcInitialConditions()[source]
calcMass()[source]
calcVolume()[source]
compartments = [][source]
density = None[source]
dryWeight = None[source]
extracellularVolume = None[source]
fractionDryWeight = None[source]
getComponentById(id, components=None)[source]
getSpeciesCountsDict()[source]
growth = None[source]
mass = None[source]
parameters = [][source]
reactions = [][source]
references = [][source]
setComponentIndices()[source]
setSpeciesCountsDict(speciesCountsDict)[source]
setupSimulation()[source]
species = [][source]
speciesCounts = array([], dtype=float64)[source]
submodels = [][source]
volume = None[source]
class intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.Parameter(id='', name='', submodel='', value=None, units='', comments='')[source]

Bases: object

comments = ''[source]
id = ''[source]
index = None[source]
name = ''[source]
submodel = None[source]
units = ''[source]
value = None[source]
class intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.RateLaw(native='')[source]

Bases: object

getModifiers(species, compartments)[source]
native = ''[source]
transcode(species, compartments)[source]
transcoded = ''[source]
class intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.Reaction(id='', name='', submodel='', reversible=None, participants=[], enzyme='', rateLaw='', vmax=None, km=None, crossRefs=[], comments='')[source]

Bases: object

comments = ''[source]
crossRefs = [][source]
enzyme = ''[source]
id = ''[source]
index = None[source]
km = None[source]
name = ''[source]
participants = [][source]
rateLaw = None[source]
reversible = None[source]
submodel = ''[source]
vmax = None[source]
class intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.ReactionParticipant(species='', compartment='', coefficient=None)[source]

Bases: object

calcIdName()[source]
coefficient = None[source]
compartment = ''[source]
id = ''[source]
name = ''[source]
species = ''[source]
class intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.Reference(id='', name='', crossRefs=[], comments='')[source]

Bases: object

comments = ''[source]
crossRefs = [][source]
id = ''[source]
index = None[source]
name = ''[source]
class intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.Species(id='', name='', structure='', empiricalFormula='', molecularWeight=None, charge=None, type='', concentrations=[], crossRefs=[], comments='')[source]

Bases: object

charge = None[source]
comments = ''[source]
concentrations = [][source]
containsCarbon()[source]
crossRefs = [][source]
empiricalFormula = ''[source]
id = ''[source]
index = None[source]
molecularWeight = None[source]
name = ''[source]
structure = ''[source]
type = ''[source]
class intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.SpeciesCompartment(index=None, species='', compartment='')[source]

Bases: object

calcIdName()[source]
compartment = ''[source]
id = ''[source]
index = None[source]
name = ''[source]
species = ''[source]
class intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.SsaSubmodel(*args, **kwargs)[source]

Bases: intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.Submodel

setupSimulation()[source]
class intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.Submodel(id='', name='', reactions=[], species=[])[source]

Bases: object

algorithm = ''[source]
static calcReactionRates(reactions, speciesConcentrations)[source]
static executeReaction(speciesCounts, reaction)[source]
extracellularVolume = array([], dtype=float64)[source]
getComponentById(id, components)[source]
getSpeciesConcentrations()[source]
getSpeciesVolumes()[source]
id = ''[source]
index = None[source]
name = ''[source]
parameters = [][source]
reactions = [][source]
setupSimulation()[source]
species = [][source]
speciesCounts = array([], dtype=float64)[source]
updateGlobalCellState(model)[source]
updateLocalCellState(model)[source]
volume = array([], dtype=float64)[source]
intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.getModelFromExcel(filename)[source]
intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.model.parseStoichiometry(rxnStr)[source]

7.1.1.1.1.1.1.4. intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.simulation module

Simulates metabolism submodel

@author Jonathan Karr, karr@mssm.edu @date 3/24/2016

intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.simulation.analyzeResults(mdl, time, volume, growth, speciesCounts, output_directory)[source]
intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.simulation.main(output_directory='/root/project/intro_to_wc_modeling/cell_modeling/simulation/multi_algorithm/../../../../docs/cell_modeling/simulation/multi_algorithm_simulation')[source]

Run simulation and plot results

Parameters

output_directory (str, optional) – directory to save plots

Returns

model numpy.ndarray: time numpy.ndarray: predicted volume dynamics numpy.ndarray: predicted growth rate dynamics numpy.ndarray: predicted species counts dynamics

Return type

model.Model

intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.simulation.simulate(mdl)[source]

7.1.1.1.1.1.1.5. intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.submodel_simulation module

Simulates metabolism submodel

@author Jonathan Karr, karr@mssm.edu @date 3/24/2016

intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.submodel_simulation.analyzeResults(mdl, time, volume, growth, speciesCounts, output_directory)[source]
intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.submodel_simulation.main(output_directory='/root/project/intro_to_wc_modeling/cell_modeling/simulation/multi_algorithm/../../../../docs/cell_modeling/simulation/multi_algorithm_submodel_simulation')[source]

Run simulation, plot results, and save plots

Parameters

output_directory (str, optional) – directory to save plots

Returns

model numpy.ndarray: time numpy.ndarray: predicted volume dynamics numpy.ndarray: predicted growth rate dynamics numpy.ndarray: predicted species counts dynamics

Return type

model.Model

intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.submodel_simulation.simulate(mdl)[source]

7.1.1.1.1.1.1.6. intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.util module

Utility functions

@author Jonathan Karr, karr@mssm.edu @date 3/22/2016

intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.util.nanmaximum(x, y)[source]
intro_to_wc_modeling.cell_modeling.simulation.multi_algorithm.util.nanminimum(x, y)[source]

7.1.1.1.1.1.1.7. Module contents