load_orgdb_annotations: Load organism annotation data from an orgdb sqlite package.

View source: R/annotation_orgdb.R

load_orgdb_annotationsR Documentation

Load organism annotation data from an orgdb sqlite package.

Description

Creates a dataframe gene and transcript information for a given set of gene ids using the AnnotationDbi interface.

Usage

load_orgdb_annotations(
  orgdb = NULL,
  gene_ids = NULL,
  include_go = FALSE,
  keytype = "ensembl",
  strand_column = "cdsstrand",
  start_column = "cdsstart",
  end_column = "cdsend",
  chromosome_column = "cdschrom",
  type_column = "gene_type",
  name_column = "cdsname",
  fields = NULL,
  sum_exon_widths = FALSE
)

Arguments

orgdb

OrganismDb instance.

gene_ids

Search for a specific set of genes?

include_go

Ask the Dbi for gene ontology information?

keytype

mmm the key type used?

strand_column

There are a few fields I want to gather by default: start, end, strand, chromosome, type, and name; but these do not necessarily have consistent names, use this column for the chromosome strand.

start_column

Use this column for the gene start.

end_column

Use this column for the gene end.

chromosome_column

Use this column to identify the chromosome.

type_column

Use this column to identify the gene type.

name_column

Use this column to identify the gene name.

fields

Columns included in the output.

sum_exon_widths

Perform a sum of the exons in the data set?

Details

Tested in test_45ann_organdb.R This defaults to a few fields which I have found most useful, but the brave or pathological can pass it 'all'.

Value

Table of geneids, chromosomes, descriptions, strands, types, and lengths.

See Also

[AnnotationDbi] [AnnotationDbi::select()] [GenomicFeatures]

Examples

 hs_orgdb_annot <- load_orgdb_annotations()
 summary(hs_orgdb_annot$genes)

elsayed-lab/hpgltools documentation built on May 9, 2024, 5:02 a.m.