Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • rsource tutorial

    Dear stata user (and R user)

    I am a stata user since many years but for some tasks I need to use R .
    I have downloaded and installed Rsource but when I try basic things such as :
    creating a do-file which is calling an R file then my results window on STATA just write:

    Assumed R program path: "C:\Program Files\R\R-3.1.0\bin\x64"
    Beginning of R output
    End of R output

    so I can't see the output of my R code.
    Do you have any idea or tutorial from which I can make some tests

    Thanks in advances

    Leila

  • #2
    Please follow FAQ advice and show us exactly what you typed into Stata, and exactly what Stata returned, Also, following the FAQ again, you should tell us the provenance of user-written commands! (rsource, by Roger Newson, is on SSC.) If you don't do these sorts of things mentioned in the FAQ, readers are less likely to bother to assist you.

    Did you use the rpath(R_pathname) specification in your use of rsource? As stated in the help file
    rpath(R_pathname) specifies a path name for invoking the R command. If rpath() is not specified, then it
    is set to the value of the global macro Rterm_path, if that macro has been specified, and to
    "Rterm.exe" otherwise. (See Technical note below.)

    Comment


    • #3
      Several options out there via google:

      http://danielmarcelino.com/running-r...ata-on-mac-os/
      http://statlore.wordpress.com/2013/0...-r-from-stata/
      __________________________________________________ __
      Assistant Professor, Department of Biostatistics and Epidemiology
      School of Public Health and Health Sciences
      University of Massachusetts- Amherst

      Comment


      • #4
        You need to specify both the path to R and the --vanilla option as global macros - then it should work.

        Comment


        • #5
          Many thanks for you answer I found the bug

          Comment

          Working...
          X