Create model (in GUI) without creating a compartment parameter

78 views
Skip to first unread message

Torkel Loman

unread,
Jan 10, 2024, 2:31:59 AMJan 10
to COPASI User Forum
I'm trying to create a simple model using the GUI (to save as SBML). However, when I check the rates, there seems to be a compartment parameter that appears and scales all the rates (might be a artefact of my SBML loader, but don't think so).

Is this something that happens by default, and if so, is there a way to disable it? I realise that the compartment feature is useful if you have several, or would want to tune the volume. But for the large number of models wherethis is not the case, it would be neat not to introducethis additional parameter (even if I can set it to 1). E.g. here this seems to be avoidable: https://pythonscriptingmanual.readthedocs.io/en/latest/building_sbml_models_using_tellurium.html

Cheers,
Torkel

Frank Bergmann

unread,
Jan 10, 2024, 2:39:00 AMJan 10
to COPASI User Forum
The multiplication with the volume is indeed done automatically, this ensures that it is easier to have consistent units, and helps to have correct models once they get bigger and several (possibly growing compartments) get into play [1].

There is no way in COPASI to disable this for the SBML import. The best I could do is to provide a python code snippet that removes the multiplication from the resulting SBML file. 

best
Frank

[1]: Hofmeyr, Jan-Hendrik S. "Kinetic modelling of compartmentalised reaction networks." Biosystems 197 (2020): 104203. https://www.sciencedirect.com/science/article/pii/S0303264720300976   

Torkel Loman

unread,
Jan 10, 2024, 9:04:58 AMJan 10
to COPASI User Forum
Dear Frank,
thank you, that is very helpful. Do you have such a snipper available? I am trying to create an SBML file to try some importers in Julia language, and would need to have it in the format without the concentration. I tried to create the file using Antimony as well, using the instructions in their documentation, but the resulting file does not seem to be readable.
Kind regards,
Torkel

Hoops, Stefan (sh9cq)

unread,
Jan 10, 2024, 10:06:59 AMJan 10
to copasi-u...@googlegroups.com
Hello Torkel,

I would very much advice against removing the compartment. In SBML the
kinetic law must return values in extend unit per time unit. Extend
unit is normally amount unit. You will have to very be careful so that
other tools will get your intend correct. Note, in SBML there is always
a compartment in which a reaction takes place thus the multiplication
with the compartment is required to convert extend unit to
concentration unit.

Thanks,
Stefan
--
Stefan Hoops, Ph.D.
Research Associate Professor
Biocomplexity Institute & Initiative
University of Virginia
995 Research Park Boulevard
Charlottesville, VA 22911

Phone: +1 540 570 1301
Email: sho...@virginia.edu

Torkel Loman

unread,
Jan 10, 2024, 10:12:12 AMJan 10
to COPASI User Forum
Dear Stefan
thanks for the quick reply. I see, will have to think more on how to deal with this.
Kind regards,
Torkel

Frank Bergmann

unread,
Jan 12, 2024, 4:29:42 AMJan 12
to COPASI User Forum
With the mentioned caveats in mind, here the script you asked for: 


best
Frank

Reply all
Reply to author
Forward
0 new messages