clusterProfiler - get symbol from GSEA results
2
0
Entering edit mode
@jane-merlevede-5019
Last seen 6.2 years ago

Hello,

Is there a way to get symbol instead of ENREZID in the results of GSEA(), as one can get when using readable = TRUE with enrichGO() for example?

Thank you

 

 

clusterProfiler • 3.2k views
ADD COMMENT
1
Entering edit mode
Guangchuang Yu ★ 1.2k
@guangchuang-yu-5419
Last seen 8 weeks ago
China/Guangzhou/Southern Medical Univer…
setReadable(gsegmt_c2, OrgDb=org.Hs.eg.db, keytype = "ENTREZID")

 

ADD COMMENT
0
Entering edit mode

Thank you for your help, I am getting the symbols.

ADD REPLY
0
Entering edit mode

this commit will give user more friendly/informative error msg and fixed the `show` method issue.

ADD REPLY
0
Entering edit mode
Guangchuang Yu ★ 1.2k
@guangchuang-yu-5419
Last seen 8 weeks ago
China/Guangzhou/Southern Medical Univer…

?setReadable

ADD COMMENT
0
Entering edit mode

I don't manage to use setReadable on GSEA results. I guess it is not possible since it should be use on enrich() results:

setReadable {DOSE}    R Documentation
setReadable
Description

mapping geneID to gene Symbol
Usage

setReadable(x, OrgDb, keytype = "auto")

Arguments
x     

enrichResult Object

 

c2 <- read.gmt("/PathwayAnalysis/GSEA/c2.all.v5.2.entrez.gmt")
gsegmt_c2 <- GSEA(geneList=input_gseGO, exponent=1, nPerm=1000, minGSSize=10, maxGSSize=900, pvalueCutoff=0.01, pAdjustMethod="BH", TERM2GENE=c2, TERM2NAME=NA,verbose=TRUE, seed=TRUE, by="fgsea")
[1] "preparing geneSet collections..."
[1] "GSEA analysis..."
[1] "leading edge analysis..."
[1] "done..."

dim(gsegmt_c2)
[1] 1134   11

gsegmt_c2[1:2,]
                                                                                               ID                                      Description setSize enrichmentScore
ACEVEDO_LIVER_CANCER_DN                                                   ACEVEDO_LIVER_CANCER_DN                          ACEVEDO_LIVER_CANCER_DN     526       0.3531918
ACEVEDO_LIVER_TUMOR_VS_NORMAL_ADJACENT_TISSUE_DN ACEVEDO_LIVER_TUMOR_VS_NORMAL_ADJACENT_TISSUE_DN ACEVEDO_LIVER_TUMOR_VS_NORMAL_ADJACENT_TISSUE_DN     268       0.3535863
                                                      NES      pvalue    p.adjust     qvalues rank                   leading_edge
ACEVEDO_LIVER_CANCER_DN                          1.350648 0.000999001 0.005652905 0.002867692 7344 tags=48%, list=35%, signal=32%
ACEVEDO_LIVER_TUMOR_VS_NORMAL_ADJACENT_TISSUE_DN 1.324621 0.000999001 0.005652905 0.002867692 7973 tags=50%, list=38%, signal=31%

  core_enrichment
ACEVEDO_LIVER_CANCER_DN .../9719/55665/28992/57088/79683/8424/26017/6539/56926/7538/2203/3727/4913/5621
ACEVEDO_LIVER_TUMOR_VS_NORMAL_ADJACENT_TISSUE_DN  .../8425/2203/3727/5621/2267/132884/26512/8876/120425/83452/5745/54436
setReadable(gsegmt_c2, OrgDb=org.Hs.eg.db, keytype = "auto")
Error in if (!keytype %in% kt) { : argument is of length zero

I can apply setReadable to enricher() but enricher() and GSEA() do not give the same results:

enrichment_gmt <- enricher(input_gseGO,pvalueCutoff = 0.01, pAdjustMethod = "BH", minGSSize = 10, maxGSSize = 900, qvalueCutoff = 0.01, TERM2GENE=c2, TERM2NAME=NA)

dim(enrichment_gmt)
[1] 3529    9

enrichment_gmt[1:2,]
ID                     Description GeneRatio   BgRatio        pvalue      p.adjust        qvalue
ENK_UV_RESPONSE_KERATINOCYTE_UP ENK_UV_RESPONSE_KERATINOCYTE_UP ENK_UV_RESPONSE_KERATINOCYTE_UP  493/7982 530/21078 5.217953e-163 2.220761e-159 2.444199e-160
HSIAO_HOUSEKEEPING_GENES               HSIAO_HOUSEKEEPING_GENES        HSIAO_HOUSEKEEPING_GENES  379/7982 389/21078 1.000970e-145 2.130063e-142 2.344376e-143
geneID
ENK_UV_RESPONSE_KERATINOCYTE_UP .../302/262/239/231/226/222/211/146/133/81/51/50/37/30/25
HSIAO_HOUSEKEEPING_GENES  .../387/378/377/375/369/355/334/328/311/302/293/292/226/166/142/71/60/16/14/12
                                Count
ENK_UV_RESPONSE_KERATINOCYTE_UP   493
HSIAO_HOUSEKEEPING_GENES          379

 

Is there another way to use setReadable with GSEA()?

ADD REPLY

Login before adding your answer.

Traffic: 299 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6