主要内容

sbiosaveproject

R2026b

Save all models in root object

Syntax

sbiosaveproject projFilename
sbiosaveproject projFilename model1
sbiosaveproject projFilename model1 model2 ...

Description

sbiosaveproject projFilename saves all models in the SimBiology® root object to the binary SimBiology project file named projFilename.sbproj. The project can be loaded with sbioloadproject. sbiosaveproject returns an error if projFilename.sbproj is not writable.

sbiosaveproject creates the binary SimBiology project file named simbiology.sbproj. sbiosaveproject returns an error if this is not writable.

sbiosaveproject projFilename model1 saves only the variable named model1, that represents a SimBiology.Model object.

sbiosaveproject projFilename model1 model2 ... saves the specified variables in the project.

Use the functional form of sbiosaveproject when the file name is stored in a character vector. For example, if the file name is stored in the variable fileName = 'myproject.sbproj' and you want to store the variables model1 and model2, type sbiosaveproject (fileName,'model1','model2') at the command line.

Examples

collapse all

Import oscillator and lotka models from SBML files.

oscModel = sbmlimport ("oscillator.xml");
lotkaModel = sbmlimport("lotka.xml");

Save both models to a SimBiology project file named oscillator_lotka_models.sbproj.

sbiosaveproject oscillator_lotka_models oscModel lotkaModel

You can use sbioloadproject to reload the models from the SBPROJ file.

Version History

Introduced in R2006a

expand all