topGodata class is not defined

Im trying to develop a shiny app to run an Gene Ontology analysis with the topGO package (

If i run the script to do the analysis in local machine out of shiny , the gene analysis runs fine, problem is when I implemented the analysis in a shiny app and got a "topGodata class is not defined" error.

Here are my code:


#geneID function
geneID <- reactive ({
  geneid <- rownames(results())

#interesting genes list
myInterestingGenes <- reactive({
  myInterestingGenes <- rownames(selected())

#genelist for go function
geneList <- reactive({
  geneList <- factor(as.integer(geneID() %in% myInterestingGenes()))
  names(geneList) <- geneID()

#create topGodata objetc
godata <- reactive({
   topgo<- new(Class = "topGodata", ontology ="BP", allGenes = geneList(),
               nodeSize =10, annot = annFUN.db, affyLib = "clariomshumantranscriptcluster.db")

#print topGO object

output$topgo <- renderText({

I am able to print the list of genes from geneList() function, but when I try to define the topGodata object I get the not define class error