R with C++ (QtCreator, Windows, Rcpp, RInside)

狂风中的少年 提交于 2019-12-11 04:54:50

问题


I have a problem when it comes to using R within the C++ code. I'd like to create UI in c++ and do all needed calculations in R. So i've found stuff like Rcpp and RInside and even though i've read a lot from Dirk Eddelbuettel's site, i'm not able to compile even the easiest program from examples attached to RInside. Obviously there is a problem with QtCreator config, I've been trying to make it right, but with no success. What i'm asking for would be step-by-step explanation of QT adjustment for R. What i already have:

  • binary for windows (installed)
  • RTools (installed)
  • QtCreator with MinGW (installed)
  • RInside and Rcpp (installed with install.packages(c("Rcpp", "RInside")) )

To be more specific, i've done everything from here: http://www.r-bloggers.com/installing-rcpp-on-windows-7-for-r-and-c-integration/

What i would like to do is to create a new project in Qt, write it in c++ and some of the functions would use R for calculations and plot. So what should i do?

Those are the errors: oi41.tinypic.com/20stzsj.jpg

And when i added LIBS errors are gone, but program does nothing: http://oi44.tinypic.com/qnk5sp.jpg

来源:https://stackoverflow.com/questions/21268223/r-with-c-qtcreator-windows-rcpp-rinside

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!