Description Usage Arguments Details Examples
View source: R/get_ont_level.R
In this function, ontology level refers to the number of generations of sub-phenotypes a term has below it in the HPO DAG. For example, the root of the HPO is term "HP:0000001", the longest path to a term with no child terms is 14. In otherwords there are 14 generations of "is-a" relationships below HP:0000001 and it is therefore at ontology level 14. A term with no sub-phenotypes below it (a leaf node), is at ontology level 0.
1 | get_ont_level(hpo, term_ids)
|
hpo |
The Human phenotype ontology data object, available in ontologyIndex package <list> |
term_ids |
A HPO Id (e.g. "HP:0000001") or a vector of multiple Ids <string> or <vector<string>> |
Typically this function should be used to get the level of a single term, but you can supply a vector of multiple terms and it will return the level of the highest level term in that vector.
1 2 3 4 5 | ## Not run:
term_ids <- "HP:0000001"
get_ont_level(hpo,term_ids)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.