Input and output

File I/O and serialization

COBREXA.load_modelMethod
load_model(file_name::String)::MetabolicModel

Generic function for loading models that chooses a specific loader function from the file_name extension, or throws an error.

Currently, these model types are supported:

source
COBREXA.load_modelMethod
load_model(type::Type{T}, file_name::String)::T where T

Helper function tht loads the model using load_model and return it converted to type.

Example:

load_model(CoreModel, "mySBMLModel.xml")
source
COBREXA.save_modelMethod
save_model(model::MetabolicModel, file_name::String)

Generic function for saving models that chooses a specific writer function from the file_name extension, or throws an error.

Currently, these model types are supported:

source
COBREXA.load_json_modelMethod
load_json_model(filename::String)::JSONModel

Load and return a JSON-formatted model that is stored in file_name.

source
COBREXA.save_json_modelMethod
save_json_model(model::MetabolicModel, file_name::String)

Save a JSONModel in model to a JSON file file_name.

In case the model is not JSONModel, it will be converted automatically.

source
COBREXA.load_mat_modelMethod
load_mat_model(file_name::String)

Load and return a MATLAB file file_name that contains a COBRA-compatible model.

source
COBREXA.save_mat_modelMethod
save_mat_model(model::MetabolicModel, file_name::String; model_name::String="model")

Save a MATModel in model to a MATLAB file file_name in a format compatible with other MATLAB-based COBRA software.

In case the model is not MATModel, it will be converted automatically.

model_name is the identifier name for the whole model written to the MATLAB file; defaults to just "model".

source

Pretty printing

Base.showMethod

Pretty printing of everything metabolic-modelish.

source
Base.showMethod
Base.show(io::IO, ::MIME"text/plain", m::Serialized{M}) where {M}

Show the Serialized model without unnecessarily loading it.

source