简体   繁体   中英

R package present in library, but still not found when required to install other packages

I need to work with R package ChaMP , for which I need to install DMRcate , for which I need IlluminaHumanMethylation450kanno.ilmn12.hg19 . I have installed "IlluminaHumanMethylation450kanno.ilmn12.hg19", and it's present in the library location. When I give the command:

library("IlluminaHumanMethylation450kanno.ilmn12.hg19")

it works.

But when I try to install "DMRcate" using BiocManager:

BiocManager::install('DMRcate')

it shows this:

'getOption("repos")' replaces Bioconductor standard repositories, see '?repositories' for details

replacement repositories:
    CRAN: https://cran.rstudio.com/

Bioconductor version 3.13 (BiocManager 1.30.15), R 4.1.0 (2021-05-18)
Installing package(s) 'DMRcate'
installing the source package ‘DMRcate’

trying URL 'https://bioconductor.org/packages/3.13/bioc/src/contrib/DMRcate_2.6.0.tar.gz'
Content type 'application/x-gzip' length 344226 bytes (336 KB)
downloaded 336 KB

* installing *source* package 'DMRcate' ...
** using staged installation
** R
** inst
** byte-compile and prepare package for lazy loading
Warning: replacing previous import 'minfi::getMeth' by 'bsseq::getMeth' when loading 'DMRcate'
Error in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]) : 
  there is no package called 'IlluminaHumanMethylationEPICanno.ilm10b4.hg19'
Calls: <Anonymous> ... loadNamespace -> withRestarts -> withOneRestart -> doWithOneRestart
Execution halted
ERROR: lazy loading failed for package 'DMRcate'
* removing 'C:/Users/sainz/OneDrive/Documents/R/win-library/4.1/DMRcate'

The downloaded source packages are in
    ‘C:\Users\sainz\AppData\Local\Temp\RtmpADMXbi\downloaded_packages’
Warning message:
In .inet_warning(msg) :
  installation of package ‘DMRcate’ had non-zero exit status

It says there is no package called "IlluminaHumanMethylation450kanno.ilmn12.hg19".

Using suggestions from a similar question on StackOverflow, I tried to extract the source package from the temp location to the library location, but that gives the same error.

I'm doing this in Rstudio. I can't figure out what's missing here. Thanks in advance!

I'd guess the length of the package name is running over a path length limit on your OS (which looks like Windows). You are trying to install into

C:/Users/sainz/OneDrive/Documents/R/win-library/4.1/

and might be able to work around the limit by putting the Illumina... package into a library with a shorter name, or maybe just installing it locally, instead of into OneDrive.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM