R中spDataLarge包安装失败求助:三种官方方法均无效
安装R包spDataLarge失败的求助
我尝试通过三种方法安装R中的spDataLarge包(仓库地址:https://github.com/Nowosad/spDataLarge),但均未成功。已将R版本更新至最新的4.4.2,并修改RStudio设置:取消勾选「Tools -> Global options -> Packages -> Management」中的「Use secure download method for HTTP」选项。以下是三种安装方法的报错信息:
选项1:通过r-universe仓库安装
> install.packages("spDataLarge", repos = "https://geocompr.r-universe.dev") Installing package into ‘C:/Users/userName/AppData/Local/R/win-library/4.4’ (as ‘lib’ is unspecified) Warning in install.packages : unable to access index for repository https://geocompr.r-universe.dev/src/contrib: cannot open URL 'https://geocompr.r-universe.dev/src/contrib/PACKAGES' Warning in install.packages : package ‘spDataLarge’ is not available for this version of R A version of this package for your version of R might be available elsewhere, see the ideas at https://cran.r-project.org/doc/manuals/r-patched/R-admin.html#Installing-packages Warning in install.packages : unable to access index for repository https://geocompr.r-universe.dev/bin/windows/contrib/4.4: cannot open URL 'https://geocompr.r-universe.dev/bin/windows/contrib/4.4/PACKAGES' Warning message: In download.file(mirrors_csv_url, destfile = mirrors_csv, quiet = TRUE) : URL 'https://cran.r-project.org/CRAN_mirrors.csv': status was 'SSL connect error'
选项2:通过devtools从GitHub安装
> devtools::install_github("geocompr/geocompkg") Downloading GitHub repo geocompr/geocompkg@HEAD Error in utils::download.file(url, path, method = method, quiet = quiet, : cannot open URL 'https://api.github.com/repos/geocompr/geocompkg/tarball/HEAD'
选项3:通过drat仓库安装
> install.packages("spDataLarge", repos = "https://nowosad.github.io/drat/", type = "source") Installing package into ‘C:/Users/userName/AppData/Local/R/win-library/4.4’ (as ‘lib’ is unspecified) Warning in install.packages : unable to access index for repository https://nowosad.github.io/drat/src/contrib: cannot open URL 'https://nowosad.github.io/drat/src/contrib/PACKAGES' Warning in install.packages : package ‘spDataLarge’ is not available for this version of R A version of this package for your version of R might be available elsewhere, see the ideas at https://cran.r-project.org/doc/manuals/r-patched/R-admin.html#Installing-packages
所有尝试均未成功,恳请各位提供解决思路,谢谢!
内容的提问来源于stack exchange,提问作者Dr. Du
相关产品推荐
相关产品推荐

