get_ids {GOfuncR}R Documentation

Get the ID of a GO-category given its name

Description

Returns GO-categories given (part of) their name. Matching is not case-sensitive.

Usage

    get_ids(go_name, term_df = NULL, godir = NULL)

Arguments

go_name

character(). (partial) name of a GO-category

term_df

optional data.frame() with an ontology 'term' table. Alternative to the default integrated GO-graph or godir.

godir

optional character() specifying a directory that contains the ontology table 'term.txt'. Alternative to the default integrated GO-graph or term_df.

Details

For details on how to use a custom ontology with term_df or godir please refer to the package's vignette. The advantage of term_df over godir is that the latter reads the file 'term.txt' from disk and therefore takes longer.

Value

a data.frame() with three columns: the full names (character()) of the GO-categories that contain go_name; together with the GO-domain ('cellular_component', 'biological_process' or 'molecular_function') and the GO-category IDs (character()).

Note

This is just a grep(..., ignore.case=TRUE) on the node names of the ontology.
More sophisticated searches, e.g. with regular expressions, could be performed on the table returned by get_ids('') which lists all non-obsolete GO-categories.

Author(s)

Steffi Grote

References

[1] Ashburner, M. et al. (2000). Gene Ontology: tool for the unification of biology. Nature Genetics 25, 25-29.

See Also

get_names
get_parent_nodes
get_child_nodes

Examples

## get GO-IDs of categories that contain 'gabaergic' in their names
get_ids('gabaergic')

## get GO-IDs of categories that contain 'blood-brain barrier' in their names
get_ids('blood-brain barrier')

## get all valid GO-categories
all_nodes = get_ids('')
head(all_nodes)

[Package GOfuncR version 1.0.0 Index]