read_gaf: Read a GAF file

Description Usage Arguments Value Examples

View source: R/read_gaf.R

Description

Read a GO annotation file in GAF format. Further information about the GAF format is available from the Gene Ontology Consortium.

Usage

1
2
3
read_gaf(filepath, database = NULL, accession = "UNIPROT", filter.NOT = T,
  filter.evidence = c("ND", "IPI", "IEA", "NAS"), ontology = NULL,
  propagate = T)

Arguments

filepath

the location of the GAF file. Files can be downloaded from ftp://ftp.ebi.ac.uk/pub/databases/GO/goa/

database

optionally, provide a Bioconductor 'AnnotationDbi' database to map identifiers from UniProt to some other accession

accession

optionally, the type of identifier to map UniProt accessions to using a Bioconductor 'AnnotationDbi' database. Must be a keytype in the database.

propagate

if true, and an ontology file is provided, all ancestors of a given term are associated with each protein.

filter_NOT

if true, filter annotations with the qualifier NOT

filter_evidence

optionally, specify evidence codes to filter. By default, evidence codes ND, IPI, IEA and NAS are filtered.

Value

a data.frame containing the filtered GAF file

Examples

1
2
3
4
5
6
# read human GOA and map to Ensembl, filtering IEA annotations
go <- read_gaf("goa_human.gpa.gz", database = org.Hs.eg.db,
   accession = "ENSEMBL", filter.evidence = "IEA")
# read mouse GOA and map to gene symbol, filtering IEA and IPI annotations
go <- read_gaf("goa_mouse.gpa.gz", database = org.Mm.eg.db,
   accession = "SYMBOL", filter.evidence = c("IEA", "IPI"))

skinnider/flavin documentation built on May 6, 2019, 10:49 a.m.