R gives error when trying to install EnsDb.Hsapiens.v75 package
2
0
Entering edit mode
@desaragora-22024
Last seen 4.5 years ago

I am trying to do TopGo enrichment analysis and the chip of my data is Illumina so i installed the EnsDb.Hsapiens.v75 package but it displays the following error:

annFUN.org(whichOnto="BP", feasibleGenes = subset_sorted, mapping = "EnsDb.Hsapiens.v75",ID = "ensembl")
Loading required package: EnsDb.Hsapiens.v75.db
Error in annFUN.org(whichOnto = "BP", feasibleGenes = subset_sorted, mapping = "EnsDb.Hsapiens.v75",  : 
  package EnsDb.Hsapiens.v75.db is required
In addition: Warning message:
In library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE,  :
  there is no package called 'EnsDb.Hsapiens.v75.db'
> GOdata <- new("topGOdata", ontology = "BP", allGenes = geneList, mapping = "EnsDb.Hsapiens.v75",nodeSize=5, annot = annFUN.org)

Building most specific GOs .....
Loading required package: EnsDb.Hsapiens.v75.db
Error in annotationFun(ontology, .Object@allGenes, ...) : 
  package EnsDb.Hsapiens.v75.db is required
In addition: Warning message:
In library(package, lib.loc = lib.loc, character.only = TRUE, logical.return = TRUE,  :
  there is no package called 'EnsDb.Hsapiens.v75.db'

Please Help.

go • 3.0k views
ADD COMMENT
0
Entering edit mode

Can you try installing that package and see if it installs correctly on its own

BiocManager::install("EnsDb.Hsapiens.v75")

If that produces ERRORs please post them here - if it installs without issue please try your code above again.

ADD REPLY
0
Entering edit mode

Thanks for your answer. I tried it and it displays the same error message as above :(.

ADD REPLY
0
Entering edit mode

Show the command and output of

BiocManager::install("EnsDb.Hsapiens.v75")

I have

> BiocManager::install("EnsDb.Hsapiens.v75")
Bioconductor version 3.9 (BiocManager 1.30.4), R 3.6.1 Patched (2019-08-19
  r77045)
Installing package(s) 'EnsDb.Hsapiens.v75'
also installing the dependencies 'AnnotationFilter', 'ProtGenerics', 'ensembldb'

trying URL 'https://bioconductor.org/packages/3.9/bioc/src/contrib/AnnotationFilter_1.8.0.tar.gz'
Content type 'application/x-gzip' length 311619 bytes (304 KB)
==================================================
downloaded 304 KB

trying URL 'https://bioconductor.org/packages/3.9/bioc/src/contrib/ProtGenerics_1.16.0.tar.gz'
Content type 'application/x-gzip' length 3978 bytes
==================================================
downloaded 3978 bytes

trying URL 'https://bioconductor.org/packages/3.9/bioc/src/contrib/ensembldb_2.8.0.tar.gz'
Content type 'application/x-gzip' length 3317825 bytes (3.2 MB)
==================================================
downloaded 3.2 MB

trying URL 'https://bioconductor.org/packages/3.9/data/annotation/src/contrib/EnsDb.Hsapiens.v75_2.99.0.tar.gz'
Content type 'application/x-gzip' length 79029669 bytes (75.4 MB)
==================================================
downloaded 75.4 MB

* installing *source* package 'AnnotationFilter' ...
** using staged installation
** R
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (AnnotationFilter)
* installing *source* package 'ProtGenerics' ...
** using staged installation
** R
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** testing if installed package can be loaded from temporary location
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (ProtGenerics)
* installing *source* package 'ensembldb' ...
** using staged installation
** R
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (ensembldb)
* installing *source* package 'EnsDb.Hsapiens.v75' ...
** using staged installation
** R
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** testing if installed package can be loaded from temporary location
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (EnsDb.Hsapiens.v75)

The downloaded source packages are in
    '/private/var/folders/yn/gmsh_22s2c55v816r6d51fx1tnyl61/T/RtmpBPh2XL/downloaded_packages'
>

Take a minute to format your answer by selecting any code chunks and clicking on the icon with 0's and 1's.

ADD REPLY
0
Entering edit mode

I reran the ınstallatıon step agaın and says thıs:

The downloaded source packages are in
    'C:\Users\bioinformatik\AppData\Local\Temp\RtmpOE4FGX\downloaded_packages'
installation path not writeable, unable to update packages: boot, foreign, mgcv, nlme
Warning message:
In install.packages(pkgs = doing, lib = lib, repos = repos, ...) :
  installation of package 'EnsDb.Hsapiens.v75' had non-zero exit status
ADD REPLY
0
Entering edit mode

It is hard to help debug if you do not include all the information: from the line you ran and all included output. Based on the above, we can not tell why EnsDb.Hsapiens.v75.db failed to install. Please include all output and also please try to format the responses as code output as suggested by Martin. BiocManger::install('EnsDb.Hsapiens.v75')

ADD REPLY
1
Entering edit mode
@james-w-macdonald-5106
Last seen 8 hours ago
United States

That's not the package you want to use for annFUN.org you want to use org.Hs.eg.db instead. The EnsDb packages are intended for providing genomic location data, not functional annotations.

ADD COMMENT
0
Entering edit mode

Thank you for your answer. I trıed that before and ıt gıves error:

Building most specific GOs .....
    ( 0 GO terms found. )

Build GO DAG topology ..........
    ( 0 GO terms and 0 relations. )
Error in if is.na(index) || index < 0 || index > length(nd)) stop("vertex is not in graph: ",  : 
  missing value where TRUE/FALSE needed

So, ı searched the bıoconductor page for a package about ıllumına chıp as thats the chıp of my data. I am new at R so I cannot make sense of most of the error messages I get so I thought ıt had to be related to the chıp not beıng affymetrıx. I dont know what ıs the problem now though. Thıs ıs my full code: (All the packages are ınstalled)

#set working directory
setwd("C:\\Users\\bioinformatik\\Desktop\\desaraR")

#loading the libraries
library(topGO)
library(org.Hs.eg.db)
#library(org.Hs.eg.db)

#reading the deseq2 file
rawCountData= read.table("(gse).deseq2.txt")
head(rawCountData)

#sorting the dataset
sorted1<-rawCountData[order(rawCountData$log2FoldChange),]
head(sorted1,10)

#creating a names column using the rownames
rawCountData <- data.frame(names = row.names(rawCountData))
map <- rawCountData[, 1]
names(map) <- gsub(" ", "", rawCountData[, 1])
head(map)

#selecting the top 100 genes (downregulated)
sorted1<- data.frame(names = row.names(sorted1))
subset_sorted<-sorted1[c(1:100),1]
head(subset_sorted, 10)

#accesing the biological process of the GO package
BPterms <- ls(GOBPTerm)
str(BPterms)

#finding genes of interest in the overall gene list
geneList <- factor(as.integer(map%in% subset_sorted))
names(geneList) <- map
str(geneList)

#creating topGOdata object
annFUN.org(whichOnto="BP", feasibleGenes = subset_sorted, mapping = "org.Hs.eg.db",ID = "ensembl")
GOdata <- new("topGOdata", ontology = "BP", allGenes = geneList, mapping = "org.Hs.eg.db",nodeSize=5, annot = annFUN.org)
ADD REPLY
0
Entering edit mode

What is the output of

head(geneList)
ADD REPLY
0
Entering edit mode
ENSG00000000003  0 ENSG00000000419  0 ENSG00000000457 0  ENSG00000000460  0 ENSG00000000938  0 
ENSG00000000971  0 
Levels: 0 1
ADD REPLY
0
Entering edit mode
##the annFUN.org functıon gıves thıs output:
$`GO:0000122`
[1] "ENSG00000118689" "ENSG00000065978"

$`GO:0000187`
[1] "ENSG00000119699"

$`GO:0000398`
[1] "ENSG00000065978"

$`GO:0001503`
[1] "ENSG00000185885"

##the GO object gıves:
Building most specific GOs .....
    ( 0 GO terms found. )

Build GO DAG topology ..........
    ( 0 GO terms and 0 relations. )
Error in if is.na(index) || index < 0 || index > length(nd)) stop("vertex is not in graph: ",  : 
  missing value where TRUE/FALSE needed

I do not understand what the last error means :(

ADD REPLY
1
Entering edit mode
@james-w-macdonald-5106
Last seen 8 hours ago
United States

The documentation for topGO may not be as complete as it could be, but there is some evidence as to what the geneList is supposed to be, which is a vector of p-values, with names that correspond to the underlying gene. Plus there's example data you could look at! For example

> library(topGO)
> data(geneList)
> head(geneList)
1095_s_at   1130_at   1196_at 1329_s_at 1340_s_at 1342_g_at
1.0000000 1.0000000 0.6223795 0.5412240 1.0000000 1.0000000
> summary(geneList)
   Min. 1st Qu.  Median    Mean 3rd Qu.    Max.
0.00000 0.09917 0.62238 0.55318 1.00000 1.00000

You on the other hand have a geneList that is A) a factor, and B) even if converted to numeric is only 0 and 1, which could hypothetically be p-values but it's super unlikely for that to be true.

I don't know where (or why?) you got a geneList like that, but you need to more closely follow the vignette and help pages.

ADD COMMENT

Login before adding your answer.

Traffic: 725 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