Hello! I'm trying to convert an SBML file's units into SI units, but I'm running into a problem. I've written a function to produce an SBMLDocument element called 'document' from a filename, and 'document' should contain the converted units. However, I'm not sure how to create an SBML file out of 'document'. Any help would be appreciated. Thanks!
My function is as follows. It may contain some bugs, but I need to know how to output an SBMLDocument before trying to debug.
public SBMLDocument convertToSI(String filename) {
ConversionProperties config = new ConversionProperties();
SBMLReader reader = new SBMLReader();
SBMLDocument document = reader.readSBML(filename);
int status;
if (config != null) {
status = document.convert(config);
}
return document
}