Search
Question: AffyLib query in topGO
0
gravatar for User
3 months ago by
User0
User0 wrote:

Hi,

While creating an object for topGO as :

 sampleGOdata <- new("topGOdata", description = "Simple session", ontology = "BP", allGenes = P_values, geneSel = topDiffGenes, nodeSize = 10, annot = annFUN.db, affyLib = affyLib)

what if there is no annotation database available for that particular organism in bioconductor?

Can someone tell me if there is any alternative available to use instead of the annotation databases of affylib(affyLib = affyLib).

Any guidance will be appreciated.

Thank you!

 

 

 

ADD COMMENTlink modified 3 months ago by James W. MacDonald46k • written 3 months ago by User0
1
gravatar for James W. MacDonald
3 months ago by
United States
James W. MacDonald46k wrote:

Have you read the vignette? This question seems to be covered quite well.

ADD COMMENTlink written 3 months ago by James W. MacDonald46k

I have followed the steps mentioned in the documents (both 2016 and 2017) provided in the vignette for enrichment analysis by topGO.

> library(topGO)

> geneList <- read.xlsx("genelist.xlsx", 1)
> head(geneList)
Gene_ID P_value
1 LOC_Os01g01120.1  0.0023
2 LOC_Os01g01120.1  0.0034
3 LOC_Os01g01120.1  0.0071
4 LOC_Os01g01120.1  0.0210
5 LOC_Os01g13120.1  0.0163
6 LOC_Os01g18210.1  0.0042
> rn <- paste(geneList[,1], sep="")
> P_values=geneList[,-1]
> names(P_values)<-rn
> head(P_values)
LOC_Os01g01120.1 LOC_Os01g01120.1 LOC_Os01g01120.1 LOC_Os01g01120.1 LOC_Os01g13120.1 LOC_Os01g18210.1 
0.0023           0.0034           0.0071           0.0210           0.0163           0.0042


> sum(topDiffGenes(P_values))
[1] 167


> geneid2GO <- read.xlsx("genetoGO.xlsx", 1)
> head(geneid2GO)
Gene_ID      GO_ID
1 LOC_Os01g01120.1 GO:0008152
2 LOC_Os01g01120.1 GO:0008152
3 LOC_Os01g01120.1 GO:0008152
4 LOC_Os01g01120.1 GO:0008152
5 LOC_Os01g13120.1 GO:0005773
6 LOC_Os01g18210.1 GO:0005576
> rn1 <- paste(geneid2GO[,1], sep="")
> gene2GO = geneid2GO[,-1]
> names(gene2GO)<-rn
> head(gene2GO)
LOC_Os01g01120.1 LOC_Os01g01120.1 LOC_Os01g01120.1 LOC_Os01g01120.1 LOC_Os01g13120.1 LOC_Os01g18210.1 
GO:0008152       GO:0008152       GO:0008152       GO:0008152       GO:0005773       GO:0005576 
41 Levels: GO:0000003 GO:0000166 GO:0003674 GO:0003677 GO:0003723 GO:0003824 GO:0005488 GO:0005575 ... GO:0030246


> GOdata <- new("topGOdata", ontology = "MF", allGenes = P_values, geneSel = topDiffGenes, annot = annFUN.gene2GO, gene2GO = gene2GO)


Building most specific GOs .....

( 41 GO terms found. )


Build GO DAG topology ..........


 There are no adj nodes for node: GO:0000003

Error in switch(type, isa = 0, partof = 1, -1) : 

  EXPR must be a length 1 vector

_______________________________________________

I am getting this kind of error.

 

ADD REPLYlink written 3 months ago by User0

I also tried using: 

> GOdata <- new("topGOdata", ontology = "MF", allGenes = P_values, geneSel = topDiffGenes, annot = annFUN.file(file = "GO_genelist_alldata.txt", whichOnto = "MF"), gene2GO = gene2GO)

Building most specific GOs .....
Error in annotationFun(ontology, .Object@allGenes, ...) : 
  could not find function "annotationFun"
ADD REPLYlink written 3 months ago by User0
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 2.2.0
Traffic: 207 users visited in the last hour