partOf_iri returns the IRI ofthe canonical "part_of" relationship in the database.

hasPart_iri returns the IRI ofthe canonical "has_part" relationship in the database.

Provides cached access to IRIs of terms and properties that are frequently used.



term_iri(label, type = "owl:Class", preferOntologies = NULL,
  firstOnly = TRUE)



character, the label of the term for which to obtain the IRI


character, the type of the term, as a IRI or using common namespace prefixes such as "owl", "rdf", etc. For example, "owl:Class", or "owl:ObjectProperty". The default is "owl:Class".


character, an array of ontologies to use for preference. In the case of multiple matches, matches will be reordered in the order given, and if matches are from preferred and other ontologies, those from ontologies not in the preference list will be discarded. If provided and only matches from ontologies not in the preference list are found, they will not be cached. Can be provided as OBO ontology prefixes, or full ontology IRIs. The default is no preferences.


boolean, whether to return only the first match in case of multiple matches. The default is TRUE.


Character, the IRI(s) for the requested term or property.


Requested IRIs are not hard-coded. Instead, they are dynamically retrieved from the API when first queried, and (depending on parameters) are subsequently held in cache in the session. Hence, if they were to change in the database, the R session would need to be restarted for this change to be reflected in the result.

For the frequently needed properties "part of", "has part" etc, one should use the predefined functions (partOf_iri(), hasPart_iri()), so that the correct matches are cached and used internally by the package.


term_iri("part of", type = "owl:ObjectProperty", preferOntologies = c("RO", "BFO"))
#> [1] ""
term_iri("develops from", type = "owl:ObjectProperty", preferOntologies = c("RO"))
#> [1] ""
term_iri("anatomical structure", firstOnly = FALSE)
#> [1] "" #> [2] ""