在R - MAC OSX Mavericks中安装RQuantLib

时间:2015-08-26 04:27:36

标签: r macos package quantlib

我一直在尝试在RStudio中安装RQuantLib,但想知道是否有人找到了解决方法,以便在MAC OSX Mavericks中启动并运行:

我已经从以下网址下载了OS X Snow Leopard binaries(因为Mavericks不可用) CRAN

当我运行以下代码时,它说我已经安装了软件包:

install.packages("/Volumes/3TB/R/RQuantLib_0.3.12.tgz", repos = NULL, type='source')
* installing *binary* package ‘RQuantLib’ ...
* DONE (RQuantLib)

然而,当我尝试加载它时,它失败了:

library("RQuantLib")
Error : .onLoad failed in loadNamespace() for 'RQuantLib', details:
  call: if (is.character(qc) && nchar(qc) > 1) {
  error: missing value where TRUE/FALSE needed
In addition: Warning message:
running command 'bash -c 'type -p quantlib-config' 2>/dev/null' had status 1 
Error: package or namespace load failed for ‘RQuantLib’

有人可以帮帮我吗?

会话信息:

sessionInfo()
R version 3.1.2 (2014-10-31)
Platform: x86_64-apple-darwin13.4.0 (64-bit)

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

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

loaded via a namespace (and not attached):
[1] blotter_0.8.19   grid_3.1.2       lattice_0.20-29  quantstrat_0.8.2 Rcpp_0.11.4      tools_3.1.2      zoo_1.7-11  

1 个答案:

答案 0 :(得分:1)

您需要先在计算机上安装QuantLib才能使用RQuantLib