gather_ontology_genes: Given a set of goseq data from simple_goseq(), make a list of...

View source: R/ontology_xlsx.R

gather_ontology_genesR Documentation

Given a set of goseq data from simple_goseq(), make a list of genes represented in each ontology.

Description

This function uses the GO2ALLEG data structure to reverse map ontology categories to a list of genes represented. It therefore assumes that the GO2ALLEG.rda data structure has been deposited in pwd(). This in turn may be generated by clusterProfilers buildGOmap() function if it doesn't exist. For some species it may also be auto-generated. With little work this can be made much more generic, and it probably should.

Usage

gather_ontology_genes(
  result,
  ontology = NULL,
  column = "over_represented_pvalue",
  pval = 0.1,
  include_all = FALSE,
  ...
)

Arguments

result

List of results as generated by simple_*().

ontology

Ontology to search (MF/BP/CC).

column

Which column to use for extracting ontologies?

pval

Maximum accepted pvalue to include in the list of categories to cross reference.

include_all

Include all genes in the ontology search?

...

Extra options without a purpose just yet.

Value

Data frame of categories/genes.

See Also

[simple_goseq()]

Examples

 ## Not run: 
  data <- simple_goseq(sig_genes = limma_output, lengths = annotation_df, goids = goids_df)
  genes_in_cats <- gather_genes(data, ont='BP')
 
## End(Not run)

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