希望有人能幫忙。我昨天將R更新爲3.2.0,無法解決安裝軟件包「時空」的問題。我已經嘗試卸載並重新安裝,以防這可以解決它。我認爲這個問題與包「sp」有關,但不理解錯誤信息,我的搜索不成功。安裝R包時空
install.packages("spacetime")
Installing package into ‘C:/####/R/win-library/3.2’
(as ‘lib’ is unspecified)
also installing the dependency ‘sp’
There are binary versions available but the source versions are later:
binary source needs_compilation
sp 1.0-17 1.1-0 TRUE
spacetime 1.1-3 1.1-4 FALSE
Binaries will be installed
trying URL 'http://cran.ms.unimelb.edu.au/bin/windows/contrib
/3.2/sp_1.0-17.zip'
Content type 'application/zip' length 1498250 bytes (1.4 MB)
downloaded 1.4 MB
package ‘sp’ successfully unpacked and MD5 sums checked
The downloaded binary packages are in
C:\###\downloaded_packages
installing the source package ‘spacetime’
trying URL 'http://cran.ms.unimelb.edu.au/src/contrib
/spacetime_1.1-4.tar.gz'
Content type 'application/x-gzip' length 3013768 bytes (2.9 MB)
downloaded 2.9 MB
* installing *source* package 'spacetime' ...
** package 'spacetime' successfully unpacked and MD5 sums checked
** R
** data
** demo
** inst
** preparing package for lazy loading
Error in loadNamespace(i, c(lib.loc, .libPaths()), versionCheck = vI[[i]]) :
namespace 'sp' 1.0-17 is being loaded, but = 1.1.0 is required
ERROR: lazy loading failed for package 'spacetime'
* removing 'C:####/R/win-library/3.2/spacetime'
The downloaded source packages are in
‘C:\###\downloaded_packages’
Warning messages:
1: running command '"C:/PROGRA~1/R/R-32~1.0/bin/x64/R" CMD INSTALL -l "C:\####\R\win-library\3.2" C:####/downloaded_packages /spacetime_1.1-4.tar.gz' had status 1
2: In install.packages("spacetime") :
installation of package ‘spacetime’ had non-zero exit status
我懷疑是被安裝了「SP」的錯誤版本,但我想我需要的最新版本,因此不知道我在正確讀取。
感謝@Roland - 我嘗試了不同的鏡子,得到它的工作沒有意識到他們是不同的(我是壞是這個 :) )。 如果你把這個作爲一個答案,我會正確標註 –