Adds annotation strings to a model and a species.
47 """usage: appendAnnotation <input-filename> <output-filename> 55 errors = d.getNumErrors()
58 print(
"Read Error(s):")
61 print(
"Correct the above and re-run.")
63 model_history_annotation =
"""<annotation> 64 <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:dcterms="http://purl.org/dc/terms/" xmlns:vCard="http://www.w3.org/2001/vcard-rdf/3.0#" xmlns:bqbiol="http://biomodels.net/biology-qualifiers/" xmlns:bqmodel="http://biomodels.net/model-qualifiers/"> 65 <rdf:Description rdf:about="#"> 66 <dc:creator rdf:parseType="Resource"> 68 <rdf:li rdf:parseType="Resource"> 69 <vCard:N rdf:parseType="Resource"> 70 <vCard:Family>Keating</vCard:Family> 71 <vCard:Given>Sarah</vCard:Given> 73 <vCard:EMAIL>sbml-team@caltech.edu</vCard:EMAIL> 75 <vCard:Orgname>University of Hertfordshire</vCard:Orgname> 80 <dcterms:created rdf:parseType="Resource"> 81 <dcterms:W3CDTF>1999-11-13T06:54:32Z</dcterms:W3CDTF> 83 <dcterms:modified rdf:parseType="Resource"> 84 <dcterms:W3CDTF>2007-11-31T06:54:00-02:00</dcterms:W3CDTF> 90 d.getModel().appendAnnotation(model_history_annotation)
118 n = d.getModel().getNumSpecies()
121 s = d.getModel().getSpecies(0)
123 cvterms_annotation =
"""<annotation> 124 <rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:dcterms="http://purl.org/dc/terms/" xmlns:vCard="http://www.w3.org/2001/vcard-rdf/3.0#" xmlns:bqbiol="http://biomodels.net/biology-qualifiers/" xmlns:bqmodel="http://biomodels.net/model-qualifiers/"> 125 <rdf:Description rdf:about="#"> 128 <rdf:li rdf:resource="http://www.geneontology.org/#GO:0005892"/> 129 <rdf:li rdf:resource="http://www.ebi.ac.uk/interpro/#IPR002394"/> 131 </bqbiol:isVersionOf> 134 <rdf:li rdf:resource="http://www.geneontology.org/#GO:0005895"/> 142 s.appendAnnotation(cvterms_annotation)
174 if __name__ ==
'__main__':