Hi @abarkova, I think what you're seeing is the normal behaviour. Let me explain.
Let's assume that you've loaded your ontology using the following script:
//define graph configuration]
call n10s.graphconfig.init({ handleVocabUris: "IGNORE"});
//import ontology
call n10s.onto.import.fetch("https://raw.githubusercontent.com/BRENDA-Enzymes/BTO/master/bto.owl", "RDF/XML");
// producing this as output:
╒═══════════════════╤═══════════════╤═══════════════╤════════════╤═══════════╤════════════╕
│"terminationStatus"│"triplesLoaded"│"triplesParsed"│"namespaces"│"extraInfo"│"callParams"│
╞═══════════════════╪═══════════════╪═══════════════╪════════════╪═══════════╪════════════╡
│"OK" │27029 │87688 │null │"" │{} │
└───────────────────┴───────────────┴───────────────┴────────────┴───────────┴────────────┘
The relationship that you refer to "derives from/develops from" looks like this in your ontology:
You can see the rdfs:label and the URI highlighted in yellow.
This can be looked up in neo4j by label
match (r:Relationship { label : "derives from/develops from"})
return r
or also by URI
match (r:Relationship { uri: "http://purl.obolibrary.org/obo/RO_0002202"})
return r
both return the same node representing that relationship. Something like this:
In the ontology, you can find other definitions like the one below where in the context of an owl:Restriction, you refer to the "derives from/develops from" relationship by its URI (highlighted).
This Class definition actually states that "intestinal cell line" is a subclass of the things that are connected to instances of http://purl.obolibrary.org/obo/BTO_0000648
through the "derives from/develops from" (http://purl.obolibrary.org/obo/RO_0002202
).
You'll find this information if you look up the class "intestinal cell line" by its label or URI (http://purl.obolibrary.org/obo/BTO_0000003
) just like we did before with the rel.
match (c1:Class { uri: "http://purl.obolibrary.org/obo/BTO_0000003"})-[r:SCO_RESTRICTION]->(c2)
return c1, r, c2
This should return the following:
As you can see, the relationship representing the restriction contains the onProperty
element.
You can use that if you want to get all the restrictions that refer to the "derives from/develops from" by using its URI (http://purl.obolibrary.org/obo/RO_0002202
) as follows (I'm limiting it to the first 100, because there are loads of them) :
MATCH (c1:Class)-[r:SCO_RESTRICTION { onPropertyURI : "http://purl.obolibrary.org/obo/RO_0002202"}]->(c2:Class)
RETURN c1, r, c2 limit 100
This should return a bunch of classes connected through restrictions that refer to your relationship:
You can also get them all in textual form with this query:
MATCH (c1:Class)-[r:SCO_RESTRICTION { onPropertyURI : "http://purl.obolibrary.org/obo/RO_0002202"}]->(c2:Class)
return c1.label, c1.uri, r.onPropertyURI, r.restrictionType, c2.label, c2.uri
Which should return the following:
Hope this helps.
JB.