Skip to contents

The Gene Ontology tree

Usage

go_ontology_download(
  basic = TRUE,
  tables = TRUE,
  subset = NULL,
  relations = c("is_a", "part_of", "occurs_in", "regulates", "positively_regulates",
    "negatively_regulates")
)

Arguments

basic

Logical: use the basic or the full version of GO. As written on the GO home page: "the basic version of the GO is filtered such that the graph is guaranteed to be acyclic and annotations can be propagated up the graph. The relations included are is a, part of, regulates, negatively regulates and positively regulates. This version excludes relationships that cross the 3 GO hierarchies. This version should be used with most GO-based annotation tools."

tables

In the result return data frames or nested lists. These later can be converted to each other if necessary. However converting from table to list is faster.

subset

Character: the GO subset (GO slim) name. GO slims are subsets of the full GO which "give a broad overview of the ontology content without the detail of the specific fine grained terms". This option, if not NULL, overrides the basic parameter. Available GO slims are: "agr" (Alliance for Genomics Resources), "generic", "aspergillus", "candida", "drosophila", "chembl", "metagenomic", "mouse", "plant", "pir" (Protein Information Resource), "pombe" and "yeast".

relations

Character vector: the relations to include in the processed data.

Value

A list with the following elements: 1) "names" a list with terms as names and names as values; 2) "namespaces" a list with terms as names and namespaces as values; 3) "relations" a list with relations between terms: terms are keys, values are lists with relations as names and character vectors of related terms as values; 4) "subsets" a list with terms as keys and character vectors of subset names as values (or NULL if the term does not belong to any subset); 5) "obsolete" character vector with all the terms labeled as obsolete. If the tables

parameter is TRUE, "names", "namespaces", "relations" and "subsets" will be data frames (tibbles).

Examples

# retrieve the generic GO slim, a small subset of the full ontology
go <- go_ontology_download(subset = 'generic')