Nested list from a table of ontology relations
Arguments
- relations
A data frame of ontology relations (the "relations" element of the list returned by
obo_parser
in case its argument `tables` isTRUE
).
Examples
goslim_url <-
"http://current.geneontology.org/ontology/subsets/goslim_generic.obo"
path <- tempfile()
httr::GET(goslim_url, httr::write_disk(path, overwrite = TRUE))
#> Response [http://current.geneontology.org/ontology/subsets/goslim_generic.obo]
#> Date: 2024-04-07 15:00
#> Status: 200
#> Content-Type: text/obo
#> Size: 115 kB
#> <ON DISK> /tmp/RtmpgsvP1J/file165a6058cc0c3c
obo <- obo_parser(path, tables = TRUE)
unlink(path)
rel_list <- relations_table_to_list(obo$relations)