OBO= http://purl.obolibrary.org/obo all: mf-merged.owl ######################################### # # Downloads # tsv: rhea-tsv.tar.gz tar -zxvf $< rhea-tsv.tar.gz: wget ftp://ftp.ebi.ac.uk/pub/databases/rhea/tsv/rhea-tsv.tar.gz rhea.obo: tsv/rhea2xrefs.tsv ./util/tsv2obo.pl $< > $@ rhea-biopax_lite.owl: rhea-biopax_lite.owl.gz gzip -d $< rhea-biopax_lite.owl.gz: wget ftp://ftp.ebi.ac.uk/pub/databases/rhea/biopax/$@ ######################################### # # Basic Reports # go-rhea-align-via-xref.rpt: rhea.obo blip-findall -r go -consult util/check_go.pro -i $< xref_check/4 -label -no_pred -use_tabs > $@ go-rhea-xref-cardinality.rpt: rhea-pathway_db.pro blip-findall -r go -i $< -consult util/card_report.pro card/3 -no_pred -label -use_tabs > $@.tmp && cut -f1,3-8 $@.tmp | mysort -k2 > $@ ######################################### # # Reactions # # sometimes fails? rhea-pathway_db.pro: rhea-biopax_lite.owl blip -i $< -f rdf -u biopax2_bridge_to_pathway io-convert -to pathway_db:pro > $@.tmp && ./util/fix-bp-uris.pl $@.tmp > $@ rhea-chebi.tbl: blip-findall -i rhea-pathway_db.pro -r chebi -consult util/xpgen.pro rhea_chebi/4 -label > $@ logic.pro: blip-findall -r chebi -i rhea-pathway_db.pro -consult util/xpgen.pro wfacts > $@ logic.obo: logic.pro blip -i $< io-convert -to obo -o $@ logic.owl: logic.obo owltools $< -o -f manchester $@ chebi_lite.obo: owltools $(OBO)/chebi.owl --make-subset-by-properties // -o -f obo $@ chebi_import.owl: logic.owl chebi_lite.obo owltools $< chebi_lite.obo --add-imports-from-supports --extract-module -s $(OBO)/chebi.owl -c --extract-mingraph --set-ontology-id $(OBO)/go/extensions/$@ -o file://`pwd`/$@ rhea-plus.owl: rhea.obo logic.owl owltools --create-ontology $(OBO)/rhea.owl $< logic.owl chebi_import.owl --merge-support-ontologies -o -f functional $@ mf.obo: blip ontol-query -r go -query "belongs(ID,molecular_function)" -to obo > $@.tmp && perl -npe 's@xref: RHEA@equivalent_to: RHEA@' $@.tmp >$@ #mf.owl: mf.obo # owltools $< --remove-dangling -o mf.owl rhea_import.owl: mf.obo rhea-plus.owl owltools $< rhea-plus.owl --add-imports-from-supports --extract-module -s $(OBO)/rhea.owl -c --set-ontology-id $(OBO)/go/extensions/$@ -o file://`pwd`/$@ mf-plus.owl: mf.obo rhea_import.owl owltools $< rhea_import.owl --merge-support-ontologies -o -f functional $@ #mf-inf.obo: mf-plus.owl # owltools $< --assert-inferred-subclass-axioms --allowEquivalencies --markIsInferred -o -f obo --no-check $@ # todo - fix owltools - merged sets should not have 1 member - causes problems for functional writer mf-merged.owl: mf-plus.owl owltools $< --merge-equivalent-classes -f RHEA -t GO --remove-dangling -o $@ mf-inf.obo: mf-merged.owl owltools $< --assert-inferred-subclass-axioms --allowEquivalencies --markIsInferred -o -f obo --no-check $@