0

在 Ubuntu 20.04 上加载 R 4.0.0 后。

R version 4.0.0 (2020-04-24) -- "Arbor Day"
Copyright (C) 2020 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

  Natural language support but running in an English locale

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

并加载了以下软件包:

> sessionInfo()
R version 4.0.0 (2020-04-24)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 20.04 LTS

Matrix products: default
BLAS:   /usr/lib/x86_64-linux-gnu/openblas-pthread/libblas.so.3
LAPACK: /usr/lib/x86_64-linux-gnu/openblas-pthread/liblapack.so.3

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C              
 [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8    
 [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8   
 [7] LC_PAPER=en_US.UTF-8       LC_NAME=C                 
 [9] LC_ADDRESS=C               LC_TELEPHONE=C            
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

loaded via a namespace (and not attached):
[1] compiler_4.0.0

我尝试安装包mclust,而 R 在准备延迟加载时卡住了。

> install.packages('mclust')
Installing package into ‘/home/marc/R/x86_64-pc-linux-gnu-library/4.0’
(as ‘lib’ is unspecified)
trying URL 'https://cloud.r-project.org/src/contrib/mclust_5.4.6.tar.gz'
Content type 'application/x-gzip' length 2877519 bytes (2.7 MB)
==================================================
downloaded 2.7 MB

* installing *source* package ‘mclust’ ...
** package ‘mclust’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
gfortran -fno-optimize-sibling-calls  -fpic  -g -O2 -fdebug-prefix-map=/build/r-base-Do_dS_/r-base-4.0.0=. -fstack-protector-strong  -c dmvnorm.f -o dmvnorm.o
gcc -std=gnu99 -I"/usr/share/R/include" -DNDEBUG      -fpic  -g -O2 -fdebug-prefix-map=/build/r-base-Do_dS_/r-base-4.0.0=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -g  -c init.c -o init.o
gfortran -fno-optimize-sibling-calls  -fpic  -g -O2 -fdebug-prefix-map=/build/r-base-Do_dS_/r-base-4.0.0=. -fstack-protector-strong  -c mclust.f -o mclust.o
gfortran -fno-optimize-sibling-calls  -fpic  -g -O2 -fdebug-prefix-map=/build/r-base-Do_dS_/r-base-4.0.0=. -fstack-protector-strong  -c mclustaddson.f -o mclustaddson.o
gcc -std=gnu99 -shared -L/usr/lib/R/lib -Wl,-Bsymbolic-functions -Wl,-z,relro -o mclust.so dmvnorm.o init.o mclust.o mclustaddson.o -llapack -lblas -lgfortran -lm -lquadmath -lgfortran -lm -lquadmath -L/usr/lib/R/lib -lR
installing to /home/marc/R/x86_64-pc-linux-gnu-library/4.0/00LOCK-mclust/00new/mclust/libs
** R
** data
*** moving datasets to lazyload DB
** inst
** byte-compile and prepare package for lazy loading

我等了一夜,但安装仍然卡在同一点。有谁知道如何解决这个问题?

我已经安装了不同的软件包,没有任何问题。这是已安装在我的库目录中的软件包的完整列表:

marc@hera:~/R/x86_64-pc-linux-gnu-library/4.0$ ls 
askpass     DEoptimR   generics     later       pkgbuild       readxl       tibble
assertthat  desc       ggplot2      lazyeval    pkgconfig      rematch      tictoc
backports   deSolve    glue         lifecycle   pkgload        remotes      tidyr
base64enc   digest     gridExtra    lspline     plotly         reprex       tidyselect
BH          diptest    gtable       lubridate   plyr           reshape2     tidyverse
blob        dplyr      gtools       magrittr    praise         rlang        tinytex
broom       egg        haven        markdown    prettyunits    rmarkdown    utf8
callr       ellipsis   hexbin       mime        processx       robustbase   uuid
cellranger  evaluate   highr        modelr      progress       rprojroot    vctrs
cli         fansi      hms          modeltools  promises       rstudioapi   viridisLite
clipr       farver     htmltools    mstate      ps             rvest        webshot
coda.base   flexmix    htmlwidgets  muhaz       purrr          scales       whisker
colorspace  flexsurv   httr         munsell     qpdf           selectr      withr
crayon      flextable  isoband      mvtnorm     quadprog       spatial      xfun
crosstalk   forcats    jsonlite     nlme        R6             stringi      xml2
curl        foreign    kableExtra   officer     RColorBrewer   stringr      yaml
data.table  fs         kernlab      openssl     Rcpp           sys          zip
DBI         gdata      knitr        pdftools    RcppArmadillo  systemfonts
dbplyr      gdtools    labeling     pillar      readr          testthat

4

2 回答 2

1

我遵循了@JBGruber 建议联系 R linux 邮件列表。在那里我得到了更多信息,我已经包含了存储库:

sudo add-apt-repository ppa:c2d4u.team/c2d4u4.0+
sudo apt-get update
sudo apt install r-cran-mclust

我真的不知道我做了什么,但现在它起作用了。

于 2020-06-04T13:19:30.863 回答
0

对我来说,问题在于openblas-pthread. 我将其更改为默认 blas 或者openblas-openmp我可以mclust正常安装。

于 2020-06-17T23:54:18.077 回答