Ontology Visualization with Protégé

How to use an Ontology Editor?

Selen Parlar
Analytics Vidhya
4 min readOct 30, 2019

--

In my previous posts, we have talked about graphs and databases to represent the knowledge within an application using the data and the relationships that hold between them. There are other methods that use formal specifications for knowledge representation such as vocabularies, taxonomies, thesauri, wordnets, and ontologies. In this post, we will handle the Ontologies.

What is an ontology?

In computer science, ontology is a set of concepts that includes a description of concepts and the relationships between them. Ontologies are created to limit complexity and to organize information.

What is an ontology editor?

Protégé is an open-source ontology editor and framework developed by the Stanford Center for Biomedical Informatics Research for building knowledge-based solutions. It provides a plug-and-play environment that makes it a flexible base for rapid prototyping. One can either download the desktop application or continue to use web-protégé. In this post, we will use the desktop application and show you some use cases.

Once we download, extract and open the application we see the homepage where we can start to create a new ontology or import the existing one. In this post, we will use an existing ontology called OntoBiotope habitat ontology (OBO) created and shared at one of the BioBLP Shared Tasks, Bacteria Biotope 2016.

Homepage of Protégé

Some insights of Protégé

Let’s import the OBO and get some insights. The figure above shows several tabs such as Active ontology, Entities, Individuals by class, and DL Query.

Ontology metrics tab

In the Ontology metrics table on the Active ontology tab, we see different metrics. For instance, Axiom means a single statement and we have 9915 different axioms in our ontology. Besides that, we have 2320 distinct class axioms and the number of subClassOf axioms is 2528. We also see annotation axioms which will be used to associate additional information with ontologies, entities, and axioms.

meal’s hierarchy

In the Classes view on the Entities tab, we see different asserted class hierarchies. The tree shows the subclass hierarchy that can be obtained from subClassOf assertions in the ontology. Let’s see an example hierarchy of meal node. The owl:Thing is the superclass of bacteria habitat class that has 12 equivalent classes such as food and planet classes. And lastly, the meal node is subsumed by food for human node.

We can also create some graphs based on our ontology. For instance, in the OntoGraph tab, we can create a graph by selecting entities from the class hierarchy. Below one can see the hierarchy of meal node created with the small part of our ontology.

Ontology visualization

To visualize our ontology, we need to install the Protégé VOWL (Visual Notation for OWL Ontologies) plugin from here. After downloading the VOWL jar, copy it to the plugins folder of Protégé, for macOS users, access the application directory structure by right-clicking the app icon and select “Show Package Contents” and navigate to Contents → Java → plugins and copy VOWL jar to the plugins folder. Finally, re-start Protégé and activate the plugin via Window → Tabs → VOWL.

Once we open the VOWL tab, it starts to create our entire ontology from scratch and shows all the nodes. On the right side, one can also see the selected node’s type and name.

VOWL of the OBO

If we move around the screen we will be able to see the entries in detail.

In more detail…

All in all…

Ontologies have components, classes, attributes, and relations as well as restrictions, rules, and axioms. With ontology we introduce a flexible, sharable, and reusable knowledge representation and applications like Protégé and VOWL help us to interpret this knowledge.

--

--