gmtGene2Cat {PathwaySplice} | R Documentation |
Obtains all pathways associated with a set of genes
gmtGene2Cat(pathway.file, gene.anno.file = NULL, genomeID = c("mm10", "hg19", "hg38"))
pathway.file |
Input file for the gene sets in GMT format, must be in gene symbols |
gene.anno.file |
Gene annotation file that facilitate gene id conversions when
gene ids in RNA-Seq data and |
genomeID |
Genome to be used. Options are 'mm10','hg19' or 'hg38'. |
This function reads a gene set file in https://software.broadinstitute.org/cancer/software/gsea/wiki/index.php/Data_formats#GMT:_Gene_Matrix_Transposed_file_format_.28.2A.gmt.29,
and returns a list with its name being a gene id, and each element of
the list being the pathways associated with the gene. When gene ids in RNA-Seq data differ from those in pathway database,
gene.anno.file
facilitate gene id conversions. Users can prepare this file based on the format of the example gene annotation file at
https://raw.githubusercontent.com/aiminy/GOSJ/master/data/gene_annotation.txt
A list where each entry is named by a gene and contains a vector of all the pathways associated with the gene
#using local file for pathways database dir.name <- system.file('extdata', package='PathwaySplice') hallmark.local.pathways <- file.path(dir.name,'h.all.v6.0.symbols.gmt.txt') hlp <- gmtGene2Cat(hallmark.local.pathways, genomeID='hg19') ## Not run: #using url for pathways database linked to a website hallmark.url.pathways <- paste0('https://raw.githubusercontent.com/SCCC-BBC', '/PathwaySplice/development/inst/extdata', '/h.all.v6.0.symbols.gmt.txt') hup <- gmtGene2Cat(hallmark.url.pathways, genomeID='hg19') ## End(Not run)