12

在 Ubuntu 10.04 上,我今天早上更新了 R (ubuntu) 软件包的负载。然后我尝试的第一个 R 脚本告诉我 zoo 不是为 R 3.0.0 构建的。所以我这样做了sudo R,然后update.packages(ask=F)假设它将使我在过去几年中安装的所有 CRAN 软件包同步。

但它没有,并且 zoo、Rcpp 等都不起作用。事实上,我安装的一半以上的软件包仍然是为 2.xx 构建的;清单如下 ( x=installed.packages();x[sort.list(x[,'Built']),c('Built','Version','Depends','LinkingTo','NeedsCompilation')])

这很难吗,并非所有软件包都为 3.0.0 做好了准备,我应该(在 Ubuntu 中)恢复到以前的版本吗?还是我需要为 3.xx 使用不同的 CRAN 站点?删除所有 2.x 软件包然后重新安装它们会修复它吗?或者 ...?

                    Built    Version     Depends                                                            LinkingTo             NeedsCompilation 
Defaults            "2.13.1" "1.1-1"     NA                                                                 NA                    NA               
itertools           "2.13.1" "0.1-1"     "R (>= 2.5.0), iterators(>= 1.0.0)"                                NA                    NA               
openNLP             "2.13.1" "0.0-8"     NA                                                                 NA                    NA               
reshape             "2.13.1" "0.8.4"     "R (>= 2.6.1), plyr"                                               NA                    NA               
RUnit               "2.13.1" "0.4.26"    "R (>= 2.5.0), utils (>= 2.5.0), methods (>= 2.5.0)"               NA                    NA               
multicore           "2.14.1" "0.1-7"     "R (>= 2.0.0)"                                                     NA                    NA               
RMySQL              "2.15.0" "0.9-3"     "R (>= 2.8.0), methods, DBI (>= 0.2-2), utils"                     NA                    NA               
foreach             "2.15.1" "1.4.0"     "R (>= 2.5.0)"                                                     NA                    NA               
iterators           "2.15.1" "1.0.6"     "R (>= 2.5.0), utils"                                              NA                    NA               
labeling            "2.15.1" "0.1"       NA                                                                 NA                    NA               
memoise             "2.15.1" "0.1"       NA                                                                 NA                    NA               
RColorBrewer        "2.15.1" "1.0-5"     "R (>= 2.0.0)"                                                     NA                    NA               
bitops              "2.15.2" "1.0-5"     NA                                                                 NA                    NA               
e1071               "2.15.2" "1.6-1"     "class"                                                            NA                    NA               
IBrokers            "2.15.2" "0.9-10"    "xts"                                                              NA                    NA               
mgcv                "2.15.2" "1.7-22"    "R (>= 2.14.0), stats, graphics"                                   NA                    NA               
munsell             "2.15.2" "0.4"       NA                                                                 NA                    NA               
randomForest        "2.15.2" "4.6-7"     "R (>= 2.5.0), stats"                                              NA                    NA               
rbenchmark          "2.15.2" "1.0.0"     NA                                                                 NA                    NA               
tree                "2.15.2" "1.0-33"    "R (>= 2.15.0), grDevices, graphics, stats"                        NA                    NA               
tseries             "2.15.2" "0.10-30"   "R (>= 2.10.0)"                                                    NA                    NA               
zoo                 "2.15.2" "1.7-9"     "R (>= 2.10.0), stats"                                             NA                    NA               
Cairo               "2.15.3" "1.5-2"     "R (>= 2.4.0)"                                                     NA                    NA               
dichromat           "2.15.3" "2.0-0"     "R (>= 2.10), stats"                                               NA                    NA               
digest              "2.15.3" "0.6.3"     "R (>= 2.4.1)"                                                     NA                    "yes"            
doMC                "2.15.3" "1.3.0"     "R (>= 2.14.0), foreach(>= 1.2.0), iterators(>= 1.0.0),\nparallel" NA                    "no"             
FastRWeb            "2.15.3" "1.1-0"     "R (>= 2.0.0), Cairo"                                              NA                    NA               
forecast            "2.15.3" "4.03"      "R (>= 2.14.0), stats, graphics"                                   "Rcpp, RcppArmadillo" "yes"            
fracdiff            "2.15.3" "1.4-2"     NA                                                                 NA                    NA               
ggplot2             "2.15.3" "0.9.3.1"   "R (>= 2.14), stats, methods"                                      NA                    "no"             
gtable              "2.15.3" "0.1.2"     "R (>= 2.14), grid"                                                NA                    NA               
inline              "2.15.3" "0.3.11"    "R (>= 2.4.0), methods"                                            NA                    "no"             
microbenchmark      "2.15.3" "1.3-0"     NA                                                                 NA                    "yes"            
nnet                "2.15.3" "7.3-6"     "R (>= 2.14.0), stats, utils"                                      NA                    "yes"            
PerformanceAnalytics"2.15.3" "1.1.0"     "R (>= 2.14.0), zoo, xts (>= 0.8-9)"                               NA                    NA               
plyr                "2.15.3" "1.8"       "R (>= 2.11.0)"                                                    NA                    NA               
proto               "2.15.3" "0.3-10"    NA                                                                 NA                    NA               
quantmod            "2.15.3" "0.4-0"     "Defaults, xts(>= 0.9-0), zoo, TTR(>= 0.2), methods"               NA                    NA               
Rcpp                "2.15.3" "0.10.3"    "R (>= 2.15.1)"                                                    NA                    "yes"            
RcppArmadillo       "2.15.3" "0.3.800.1" "R (>= 2.14.0), Rcpp (>= 0.10.2)"                                  "Rcpp"                "yes"            
RCurl               "2.15.3" "1.95-4.1"  "R (>= 2.7.0), methods, bitops"                                    NA                    "yes"            
reshape2            "2.15.3" "1.2.2"     NA                                                                 NA                    NA               
RInside             "2.15.3" "0.2.10"    "R (>= 2.10.0), Rcpp (>= 0.8.5)"                                   "Rcpp"                NA               
rJava               "2.15.3" "0.9-4"     "R (>= 2.5.0), methods"                                            NA                    "yes"            
rjson               "2.15.3" "0.2.12"    "R (>= 2.12.0)"                                                    NA                    NA               
Rserve              "2.15.3" "1.7-0"     "R (>= 1.5.0)"                                                     NA                    NA               
RWeka               "2.15.3" "0.4-16"    "R (>= 2.6.0)"                                                     NA                    "no"             
RWekajars           "2.15.3" "3.7.9-1"   NA                                                                 NA                    "no"             
scales              "2.15.3" "0.2.3"     "R (>= 2.12), methods"                                             NA                    NA               
slam                "2.15.3" "0.1-28"    "R (>= 2.8.0)"                                                     NA                    NA               
stringr             "2.15.3" "0.6.2"     "R (>= 2.14)"                                                      NA                    NA               
tm                  "2.15.3" "0.5-8.3"   "R (>= 2.14.0), methods"                                           NA                    NA               
TTR                 "2.15.3" "0.22-0"    "xts (>= 0.9-3)"                                                   "xts"                 "yes"            
XML                 "2.15.3" "3.96-1.1"  "R (>= 1.2.0), methods, utils"                                     NA                    "yes"            
xts                 "2.15.3" "0.9-3"     "zoo (>= 1.7-2)"                                                   "zoo (>= 1.7.2)"      NA               
xtsExtra            "2.15.3" "0.0-1"     "zoo, xts"                                                         NA                    NA               
colorspace          "3.0.0"  "1.2-2"     "R (>= 2.13.0), methods"                                           NA                    "yes"            
DBI                 "3.0.0"  "0.2-7"     "R (>= 2.15.0), methods"                                           NA                    "no"             
Hmisc               "3.0.0"  "3.10-1.1"  "R (>= 2.4.0), methods, survival"                                  NA                    "yes"            
quadprog            "3.0.0"  "1.5-5"     "R (>= 2.15.0)"                                                    NA                    "yes"            
RSQLite             "3.0.0"  "0.11.3"    "R (>= 2.10.0), methods, DBI (>= 0.2-5)"                           NA                    "yes"            
base                "3.0.0"  "3.0.0"     NA                                                                 NA                    NA               
boot                "3.0.0"  "1.3-9"     "R (>= 3.0.0), graphics, stats"                                    NA                    NA               
class               "3.0.0"  "7.3-7"     "R (>= 3.0.0), stats, utils"                                       NA                    "yes"            
cluster             "3.0.0"  "1.14.4"    "R (>= 2.10.0), stats, graphics, utils"                            NA                    "yes"            
codetools           "3.0.0"  "0.2-8"     "R (>= 2.1)"                                                       NA                    NA               
compiler            "3.0.0"  "3.0.0"     NA                                                                 NA                    NA               
datasets            "3.0.0"  "3.0.0"     NA                                                                 NA                    NA               
foreign             "3.0.0"  "0.8-53"    "R (>= 2.14.0), stats"                                             NA                    "yes"            
graphics            "3.0.0"  "3.0.0"     NA                                                                 NA                    NA               
grDevices           "3.0.0"  "3.0.0"     NA                                                                 NA                    NA               
grid                "3.0.0"  "3.0.0"     NA                                                                 NA                    NA               
KernSmooth          "3.0.0"  "2.23-10"   "R (>= 2.5.0), stats"                                              NA                    "yes"            
lattice             "3.0.0"  "0.20-15"   "R (>= 2.15.1)"                                                    NA                    "yes"            
MASS                "3.0.0"  "7.3-26"    "R (>= 3.0.0), grDevices, graphics, stats, utils"                  NA                    "yes"            
Matrix              "3.0.0"  "1.0-12"    "R (>= 2.15.0), stats, methods, utils, lattice"                    NA                    "yes"            
methods             "3.0.0"  "3.0.0"     NA                                                                 NA                    NA               
mgcv                "3.0.0"  "1.7-22"    "R (>= 2.14.0), stats, graphics"                                   NA                    NA               
nlme                "3.0.0"  "3.1-109"   "graphics, stats, R (>= 3.0.0)"                                    NA                    NA               
nnet                "3.0.0"  "7.3-6"     "R (>= 2.14.0), stats, utils"                                      NA                    "yes"            
parallel            "3.0.0"  "3.0.0"     NA                                                                 NA                    NA               
rpart               "3.0.0"  "4.1-1"     "R (>= 2.14.0), graphics, stats, grDevices"                        NA                    "yes"            
spatial             "3.0.0"  "7.3-6"     "R (>= 3.0.0), graphics, stats, utils"                             NA                    NA               
splines             "3.0.0"  "3.0.0"     NA                                                                 NA                    NA               
stats               "3.0.0"  "3.0.0"     NA                                                                 NA                    NA               
stats4              "3.0.0"  "3.0.0"     "methods, graphics, stats"                                         NA                    NA               
survival            "3.0.0"  "2.37-4"    "stats, utils, graphics, splines, R (>= 2.13.0)"                   NA                    "yes"            
tcltk               "3.0.0"  "3.0.0"     NA                                                                 NA                    NA               
tools               "3.0.0"  "3.0.0"     NA                                                                 NA                    NA               
utils               "3.0.0"  "3.0.0"     NA                                                                 NA                    NA               
4

2 回答 2

34

所需的命令不是您所说的:update.packages(ask=F)而是以下update.packages(ask=FALSE, checkBuilt=TRUE).

试试看,所有仍在维护和可用的 CRAN 包当然都会得到处理。您从 github、Simon 的 rforge、r-forge 或其他随机 repo 安装的东西需要手动帮助。

自 R 3.0.0 发布以来,该问题已在各个场所进行了详细讨论。

于 2013-05-12T02:18:47.730 回答
4

Dirk 的回答让我得到了大部分的帮助,只留下了从 R-Forge 安装的 xtsExtra。我建议 update.packages(ask=FALSE, checkBuilt=TRUE, repos="http://R-Forge.R-project.org")要这样做,因为这似乎会用他们的 R-Forge 版本更新一些 CRAN 包;这可能意味着它安装了更多的实验版本(?)。

所以,我这样做了:

remove.packages('xtsExtra')
install.packages("xtsExtra", repos="http://R-Forge.R-project.org")
于 2013-05-12T06:20:51.697 回答