I was working with Deseq2 for months and suddenly I had an error loading that. I tried to fix it but I think I made staff more complecated. Could anybody give me some advice? I even tried to unstall and reinstall R and Rstudio. But problem still there.
#> library(DESeq2)
#there is an error i can not load deseq2
#Le chargement a nécessité le package : GenomicRanges
#Error: package ‘S4Vectors’ 0.18.3 is loaded, but >= 0.19.11 is required by ‘GenomicRanges’
# I found this in google """Make sure you do not have any R sessions running.
Start R from the command line, using R --vanilla
Run BiocInstaller::biocValid() and follow directions to update / downgrade individual packages.
Use BiocInstaller:biocLite("S4Vectors") to re-install S4Vectors.
Use library(DESeq2) (no library path) to load DESeq2.
If for some reason you want to install and use packages from a particular library location, do so consistently and in a way that avoids duplicate package installations across active library paths. For instance, set .libPaths() to contain a 'session-specific' library path (e.g., Bioc version 3.4 packages) and a 'system' library path (base and recommended packages only)"""
#I tried to do as it says
BiocInstaller::biocValid()
BiocInstaller:biocLite("S4Vectors")
library(DESeq2)
#i had an error Error: object 'BiocInstaller' not found
#then I decided to remove S4Vectores and install again
remove.packages('S4Vectors')
if (!requireNamespace("BiocManager", quietly = TRUE))
install.packages("BiocManager")
BiocManager::install("S4Vectors", version = "3.8")
Bioconductor version 3.8 (BiocManager 1.30.4), R 3.5.1 (2018-07-02)
Installing package(s) 'S4Vectors'
Warning: package ‘S4Vectors’ is in use and will not be installed
Update old packages: 'BiocGenerics', 'GenomeInfoDb', 'IRanges', 'processx', 'units'
Update all/some/none? [a/s/n]:
a
also installing the dependency ‘S4Vectors’
There are binary versions available but the source versions are later:
binary source needs_compilation
processx 3.2.0 3.2.1 TRUE
units 0.6-1 0.6-2 TRUE
Binaries will be installed
Warning: packages ‘S4Vectors’, ‘BiocGenerics’, ‘GenomeInfoDb’, ‘IRanges’ are in use and will not be installed
trying URL 'https://cran.rstudio.com/bin/windows/contrib/3.5/processx_3.2.0.zip'
Content type 'application/zip' length 300367 bytes (293 KB)
downloaded 293 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/3.5/units_0.6-1.zip'
Content type 'application/zip' length 1704363 bytes (1.6 MB)
downloaded 1.6 MB
package ‘processx’ successfully unpacked and MD5 sums checked
package ‘units’ successfully unpacked and MD5 sums checked
The downloaded binary packages are in
C:\Users\Administrateur\AppData\Local\Temp\Rtmps76hIZ\downloaded_packages
library(DESeq2)# again I had an error
Error: le package ‘S4Vectors’ nécessaire pour ‘DESeq2’, mais est introuvable
#In addition: Warning message:
#"In read.dcf(file.path(p, "DESCRIPTION"), c("Package", "Version")) :
#cannot open compressed file 'C:/Program Files/R/R-3.5.1/library/S4Vectors/DESCRIPTION', probable reason 'No such file or directory'
remove.packages('DESeq2') # i tried to remove deseq2 and install it again
#Removing package from ‘C:/Program Files/R/R-3.5.1/library’
#(as ‘lib’ is unspecified)
if (!requireNamespace("BiocManager", quietly = TRUE))
install.packages("BiocManager")
BiocManager::install("DESeq2", version = "3.8")
library(DESeq2)# again I have an error
Error: le package ‘S4Vectors’ nécessaire pour ‘DESeq2’, mais est introuvable
In addition: Warning message:
In read.dcf(file.path(p, "DESCRIPTION"), c("Package", "Version")) :
cannot open compressed file 'C:/Program Files/R/R-3.5.1/library/S4Vectors/DESCRIPTION', probable reason 'No such file or directory'
> remove.packages('DESeq2')
Removing package from ‘C:/Program Files/R/R-3.5.1/library’
(as ‘lib’ is unspecified)
> if (!requireNamespace("BiocManager", quietly = TRUE))
+ install.packages("BiocManager")
> BiocManager::install("DESeq2", version = "3.8")
Bioconductor version 3.8 (BiocManager 1.30.4), R 3.5.1 (2018-07-02)
Installing package(s) 'DESeq2'
also installing the dependency ‘S4Vectors’
Warning: package ‘S4Vectors’ is in use and will not be installed
trying URL 'https://bioconductor.org/packages/3.8/bioc/bin/windows/contrib/3.5/DESeq2_1.22.1.zip'
Content type 'application/zip' length 2552570 bytes (2.4 MB)
downloaded 2.4 MB
package ‘DESeq2’ successfully unpacked and MD5 sums checked
The downloaded binary packages are in
C:\Users\Administrateur\AppData\Local\Temp\Rtmps76hIZ\downloaded_packages
Update old packages: 'BiocGenerics', 'GenomeInfoDb', 'IRanges', 'processx', 'units'
Update all/some/none? [a/s/n]:
a
also installing the dependency ‘S4Vectors’
There are binary versions available but the source versions are later:
binary source needs_compilation
processx 3.2.0 3.2.1 TRUE
units 0.6-1 0.6-2 TRUE
Binaries will be installed
Warning: packages ‘S4Vectors’, ‘BiocGenerics’, ‘GenomeInfoDb’, ‘IRanges’ are in use and will not be installed
trying URL 'https://cran.rstudio.com/bin/windows/contrib/3.5/processx_3.2.0.zip'
Content type 'application/zip' length 300367 bytes (293 KB)
downloaded 293 KB
trying URL 'https://cran.rstudio.com/bin/windows/contrib/3.5/units_0.6-1.zip'
Content type 'application/zip' length 1704363 bytes (1.6 MB)
downloaded 1.6 MB
package ‘processx’ successfully unpacked and MD5 sums checked
package ‘units’ successfully unpacked and MD5 sums checked
The downloaded binary packages are in
C:\Users\Administrateur\AppData\Local\Temp\Rtmps76hIZ\downloaded_packages
> library(DESeq2)
Error: le package ‘S4Vectors’ nécessaire pour ‘DESeq2’, mais est introuvable
In addition: Warning message:
In read.dcf(file.path(p, "DESCRIPTION"), c("Package", "Version")) :
cannot open compressed file 'C:/Program Files/R/R-3.5.1/library/S4Vectors/DESCRIPTION', probable reason 'No such file or directory'