[英]Installing ROracle
I have downloaded the compiled ROracle package from the Oracle website.我已经从 Oracle 网站下载了编译好的 ROracle 包。 I have set my working directory with
setwd()
.我已经用
setwd()
设置了我的工作目录。 Then I tried to install the package as follows:然后我尝试按如下方式安装软件包:
install.packages("ROracle-1.3.2.zip", repos=NULL)
It failed and I got the following error message:它失败了,我收到以下错误消息:
Error in read.dcf(file.path(pkgname, "DESCRIPTION"), c("Package", "Type")) :
cannot open the connection
In addition: Warning message:
In read.dcf(file.path(pkgname, "DESCRIPTION"), c("Package", "Type")) :
cannot open compressed file 'ROracle-1.3.2/DESCRIPTION', probable reason 'No such file or directory'
I also tried from command line just in case:为了以防万一,我也从命令行尝试过:
R CMD INSTALL ROracle-1.3.2.zip
It also failed and I got the following error message:它也失败了,我收到以下错误消息:
* installing to library 'Z:/R/R-3.6.1/library'
Warning in read.dcf(file.path(pkgname, "DESCRIPTION"), c("Package", "Type")) :
cannot open compressed file 'ROracle-1.3.2/DESCRIPTION', probable reason 'No such file or directory'
Error in read.dcf(file.path(pkgname, "DESCRIPTION"), c("Package", "Type")) :
cannot open the connection
The DESCRIPTION file certainly exists in ROracle-1.3.2.zip.描述文件肯定存在于 ROracle-1.3.2.zip 中。 I opened it up and looked at - just a normal DESCRIPTION file.
我打开它看了看——只是一个普通的描述文件。
I am using Windows 7.我正在使用 Windows 7。
How do I install ROracle?如何安装 ROracle?
You need to follow the following procedure:您需要遵循以下程序:
Got down into this solution by comparing hierarchy of earlier ROracle_1.3-1.zip -file which i got working well in earlier R version.通过比较我在早期 R 版本中运行良好的早期 ROracle_1.3-1.zip 文件的层次结构,深入研究了这个解决方案。
After following all these steps the outcome is that the DESCRIPTION file can be found in ROracle.zip/ROracle/DESCRIPTION
instead of ROracle-1.3.2.zip/DESCRIPTION
执行完所有这些步骤后,结果是可以在
ROracle.zip/ROracle/DESCRIPTION
而不是ROracle-1.3.2.zip/DESCRIPTION
找到描述文件
With the newly zip-file from step 4 the installation is a quite straightforward.使用第 4 步中的新 zip 文件,安装非常简单。
setwd("THEPLACEWHERETHE ROracle.zip file is located)
install.packages('ROracle.zip', repos = NULL)
My .Renviron
contains these lines if that matters如果重要的话,我的
.Renviron
包含这些行
# PATH="C:/Rtools/bin;C:/oracle/instantclient_19_5;$PATH"
# OCI_LIB64 = C:/oracle/instantclient_19_5
# BINPREF="C:/Rtools/mingw_$(WIN)/bin/"
OS is WIN10.操作系统是WIN10。 R version 3.6.2 (2019-12-12) -- "Dark and Stormy Night" Platform: x86_64-w64-mingw32/x64 (64-bit) ROracle 1.3-2
R version 3.6.2 (2019-12-12) -- 《黑夜暴风雨》平台:x86_64-w64-mingw32/x64(64位)ROracle 1.3-2
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.