我是R.的新用户。我在使用R版本3.3.3时无法加载特定软件包openssl
,而且我不确定如何修复它。输出如下所示。我还包含了用于安装 install.packages("ndtv")
trying URL 'https://cran.rstudio.com/bin/macosx/mavericks/contrib/3.3/ndtv_0.10.0.tgz'
Content type 'application/x-gzip' length 1038395 bytes (1014 KB)
==================================================
downloaded 1014 KB
The downloaded binary packages are in
/var/folders/2k/v2d50mgs4p7fcgms0t1cmzfr0000gq/T//RtmpSbDxIq/downloaded_packages
> library(ndtv)
Error in loadNamespace(j <- i[[1L]], c(lib.loc, .libPaths()), versionCheck = vI[[j]]) :
there is no package called ‘openssl’
Error: package or namespace load failed for ‘ndtv’
> install.packages("openssl")
There is a binary version available but the source version is later:
binary source needs_compilation
openssl 0.9.9 1.0.1 TRUE
Do you want to install from sources the package which needs compilation?
y/n: y
installing the source package ‘openssl’
trying URL 'https://cran.rstudio.com/src/contrib/openssl_1.0.1.tar.gz'
Content type 'application/x-gzip' length 1194261 bytes (1.1 MB)
==================================================
downloaded 1.1 MB
* installing *source* package ‘openssl’ ...
** package ‘openssl’ successfully unpacked and MD5 sums checked
Homebrew 1.5.2
Homebrew/homebrew-core (git revision d46a; last commit 2018-02-02)
Using PKG_CFLAGS=-I/usr/local/opt/openssl@1.1/include -I/usr/local/opt/openssl/include
------------------------- ANTICONF ERROR ---------------------------
Configuration failed because openssl was not found. Try installing:
* deb: libssl-dev (Debian, Ubuntu, etc)
* rpm: openssl-devel (Fedora, CentOS, RHEL)
* csw: libssl_dev (Solaris)
* brew: openssl@1.1 (Mac OSX)
If openssl is already installed, check that 'pkg-config' is in your
PATH and PKG_CONFIG_PATH contains a openssl.pc file. If pkg-config
is unavailable you can set INCLUDE_DIR and LIB_DIR manually via:
R CMD INSTALL --configure-vars='INCLUDE_DIR=... LIB_DIR=...'
--------------------------------------------------------------------
ERROR: configuration failed for package ‘openssl’
* removing ‘/Library/Frameworks/R.framework/Versions/3.3/Resources/library/openssl’
Warning in install.packages :
installation of package ‘openssl’ had non-zero exit status
The downloaded source packages are in
‘/private/var/folders/2k/v2d50mgs4p7fcgms0t1cmzfr0000gq/T/RtmpOf01bl/downloaded_packages’
的输出。我非常感谢任何指导。谢谢!
states = ('ab',['rose','cose'])