Importing template models#
RAVEN creates a draft GEM with models of phylogenetically related organisms as templates. For H. polymorpha, the S. cerevisiae model (yeast-GEM) is the primary template and the R. toruloides model (rhto-GEM) is the complementary template.
Loading the primary template#
importModel loads an SBML file into a RAVEN-format MATLAB structure:
modelSce = importModel('yeastGEM.xml');
yeast-GEM was exported with the compartment appended to each metabolite identifier. RAVEN keeps the compartment in a separate field (.metComps), so the redundant suffix is removed. The model receives the identifier sce, which getModelFromHomology later uses to match the model with its protein FASTA file:
modelSce.mets = regexprep(modelSce.mets, '\[[a-z]+\]$', '');
modelSce.id = 'sce';
Inspecting the model#
A spreadsheet is often easier for browsing a model. exportToExcelFormat writes an .xlsx file with five sheets: RXNS, METS, COMPS, GENES and MODEL:
exportToExcelFormat(modelSce, 'modelSce.xlsx');
Reconstruction often writes files that are not meant to be tracked in git. The hanpo-GEM repository keeps them in a scrap/ folder that is excluded from version control.
Make changes in MATLAB, and export the model to SBML when needed:
exportModel(modelSce, 'modelSce.xml');
Loading the complementary template#
The R. toruloides model is loaded in the same way. RAVEN wrote it, so it has no redundant compartment suffix to remove:
modelRhto = importModel('rhto.xml', true);
modelRhto.id = 'rhto';
Store intermediate states of the MATLAB workspace to resume later:
save('scrap/importModels.mat')
% load('scrap/importModels.mat')
The next page is Draft from homology.