Skip to content

Protege and label based editing (PATO:quality vs BFO:quality)

Nico Matentzoglu edited this page Mar 19, 2019 · 1 revision

When editing logical definitions manually, it often happens that Protege gets confused with which class you are referring to if there are multiple ones with the same label. The most prominent case for HP is the mix-up of BFO:quality and PATO:quality (in almost 100% of the cases, we care about the latter). There is now a QC test to identify cases where BFO:quality was used instead of PATO:quality.

What do we do to fix this? There are two alternatives.

  1. Change RENDERING MODE. Before (important: not during!) creating/editing the definition, in Protege, switch to

View -> Render by entity IRI short name (Id)

Then edit the logical axiom in the usual way and replace the wrong BFO_0000019 with PATO_0000001. Save axiom and ontology. Change the rendering mode back to View -> Render by label.

Note that when you click on the 'quality' term in the logical definition, you are not necessarily brought to the correct term in Protege. It could be that you have, if you followed the above, correctly added the PATO term, but clicking on it still causes Protege to link to the BFO term!

  1. Edit hp-edit.owl in a text editor. This is for more advanced users (only do this if you have edited HP with that very text editor before; you need to be sure the text editor does not introduce artefacts such as wrong encodings, whitespace etc), but some may prefer this option.

Search for BFO_0000019. If it occurs in an EquivalentClasses axiom such as

EquivalentClasses(<http://purl.obolibrary.org/obo/HP_0000008> ObjectSomeValuesFrom(<http://purl.obolibrary.org/obo/BFO_0000051> ObjectIntersectionOf(<http://purl.obolibrary.org/obo/BFO_0000019> ObjectSomeValuesFrom(<http://purl.obolibrary.org/obo/RO_0002314> <http://purl.obolibrary.org/obo/UBERON_0003975>) ObjectSomeValuesFrom(<http://purl.obolibrary.org/obo/RO_0002573> <http://purl.obolibrary.org/obo/PATO_0000460>))))

Simply replace it by PATO_0000001:

EquivalentClasses(<http://purl.obolibrary.org/obo/HP_0000008> ObjectSomeValuesFrom(<http://purl.obolibrary.org/obo/BFO_0000051> ObjectIntersectionOf(<http://purl.obolibrary.org/obo/PATO_0000001> ObjectSomeValuesFrom(<http://purl.obolibrary.org/obo/RO_0002314> <http://purl.obolibrary.org/obo/UBERON_0003975>) ObjectSomeValuesFrom(<http://purl.obolibrary.org/obo/RO_0002573> <http://purl.obolibrary.org/obo/PATO_0000460>))))

Remember: Always review diffs before committing to Master!