Dear Seniors and all members,
Me again!! I hope you do not mind me as a junior in RNAseq and tried to learn and finish my degree. Sorry for another question. I have done WGCNA and was able to identify the module associated with traits and exported data for Gene Ontology and network via cytoscape. I worked on mouse tumour tissue untreated or treated with radiation.
I had a module, which contains almost a 1000 genes and I would like to do gene ontology particularly over representative analysis for that module. Basically, I had gene symbol in my output and to do gene ontology, I had to convert it to entrezID. I use the following code chunk from Biomart library.
gene_id<- getBM(attributes = c("ensembl_gene_id", "external_gene_name", "entrezgene_id"), mart = useDataset("mmusculus_gene_ensembl", useMart("ensembl")))
Here is the output I got.
and I used the following code chunk to map entrezID to my gene symbol
d1<- merge(d, gene_id[,c(2,3)], by.x="GeneID", by.y="external_gene_name")
## Gene Ontology
I first used ClusterProfiler to perform GO over representative analysis using the following code after creating genelist.
ego <- enrichGO(gene = gene, universe = names(geneList), OrgDb = org.Mm.eg.db, ont = "BP", pAdjustMethod = "BH", pvalueCutoff = 0.01, qvalueCutoff = 0.05, readable = TRUE)
I got error as shown in the following
--> No gene can be mapped.... --> Expected input gene ID: 75002,70099,50796,104310,71099,18663 --> return NULL...
I guess I had the correct entrezID in my genelist, which is integer. Why there was no gene that can be mapped? I had read previous posts in biostar from members, who had experienced the same problem and our members said these are not mouse entrezID. May I ask whether my code chunk used to generate generate entrezID is correct for mouse organism.
Also, I have try another option in R using
library(GO.db)
library(GOstats)
selectgene<- unique(d1naf['entrezgene_id'])
unversegene<- unique(d1naf$entrezgene_id)
cutoff= 0.05
testing<- new("GOHyperGParams", geneIds= selectgene, universeGeneIds= unversegene, annotation= "org.Mm.eg.db", ontology= "BP", pvalueCutoff= cutoff, conditional= FALSE, testDirection="over")
GOtest<- hyperGTest(testing)
summary(GOtest)
Here is the output
summary(GOtest)
1 GOBPID Pvalue OddsRatio ExpCount Count Size Term
<0 rows> (or 0-length row.names)
Warning message: No results met the specified criteria. Returning 0-row data.frame >
Does this mean my genelist is not found in any GO geneset or just because the error with entrezID conversion? it is weird because I had lots of genes and I should have gotten some outputs. Thank for taking time reading my question. Is there any online web-interface to do gene ontology outside R? looking forward to hearing from all seniors and members soon.
Kind Regards,
Synat,
Looks like you hit
Save
before completing the post. You can edit and complete.Dear GenoMax,
Thank you so much for your quick response. I had error and now completed my post. wondering if you could have a look and suggest sth.
Kind Regards, synat