DateOctober 25, 2010

How to use ecell from an ipython console with pylab

If you use Ecell simulator sometimes it’s handy to have a way to use it inside an ipython/pylab session to quickly test some features and try some small thing.

For this reason I’ve created a class called quickEcell which takes care to initialize ecell simulator, create the ses object and offer a qcuik way to create loggers and plot the variable.

Below is the minimal to run a model and plot it. All the code is on http://github.com/mattions/QuickEcell

[code]"""Demo method. This should be the skeleton of your simulation"""

qE = QuickEcell(‘simple_ecell_mod.eml’)
variables = [‘S’, ‘P’]
loggers = qE.create_loggers(variables)
qE.run_and_plot(1000, variables, loggers)
plt.title("Test for Michaelis-Menten")
plt.show()[/code]

La DeLorean elettrica in viaggio per l’Italia

Quelli di wired italia hanno fatto il retrofitting da benzina a elettrica di una De Lorean e sono partiti, oggi!

© 2017 Train of Thoughts

Theme by Anders NorénUp ↑

By continuing to use the site (scrolling or clicking counts), you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.

Close