On Nov 29, 2012 a new version of RStudio released that makes it possible to " write C++ functions and simply source them into R just as you'd source an R script " . I became super-interested thinking that similar to integration of knitr and Latex into RStudio which enables me to use RStudio for both my R programs and Latex codes, the new version enables me to do the same with my C++ codes. I'm beginner in C++ and I thought that now that Rstudio has made it easy to program in C++ and source it in R, it's a great time to start learning C++ which I really need for my project involving heavy computations. After downloading the new version and creating a new .cpp file and writing a simple C++ code, I'm not able to compile it. Would you please guide me on:
1) Whether the new RStudio can be used as an editor for writing and running my C++ codes instead of Visual Studio or other editors/IDEs?(Similar to what I do with my Latex codes)
2) If so, I assume that I need to set up C++ compiler separately, would you guide me on how to do that in mac?
3) like loading knitr package, do I need to load any package in R to be able to source/or run my C++ codes in Rstudio?
3) Finally, do I need to set the RStudio preferences to be able to compile my C++ codes directly from RStudio?
Quick ones regarding your questions:
Try Google, RSeek.org and the SO search features. These questions have all been asked, and answered, before.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.