Thanks to Kit Baum, a new version of the -rsource- package is now
available for download from SSC. In Stata, use the -ssc- or -
adoupdate-
commands to do this.
The -rsource- package is described as below my signature on my
website.
The new version is updated to Stata Version 10. However, users of
Stata
9 can still download the Stata 9 version from my website by typing
net from "http://www.imperial.ac.uk/nhli/r.newson/stata9/"
in Stata, and selecting -rsource-.
The new version also incorporates a new default setting for the
-rpath()- option (if the global macro -Rterm_path- is not specified),
which is now -rpath("/usr/bin/r")- in non-Windows operating
environments, and is still -rpath("Rterm.exe")- in Windows operation
environments. I have not yet tested this improvement in non-Windows
environments, so please let me know if there are any problems. I would
like to thank Kit Baum for sugggesting this improvement, and David
Airey
and Michael Hanson for raising the platform-independence issue.
Best wishes
Roger
Roger B Newson BSc MSc DPhil
Lecturer in Medical Statistics
Respiratory Epidemiology and Public Health Group
National Heart and Lung Institute
Imperial College London
Royal Brompton Campus
Room 33, Emmanuel Kaye Building
1B Manresa Road
London SW3 6LR
UNITED KINGDOM
Tel: +44 (0)20 7352 8121 ext 3381
Fax: +44 (0)20 7351 8322
Email: [email protected]
Web page: http://www.imperial.ac.uk/nhli/r.newson/
Departmental Web page:
http://www1.imperial.ac.uk/medicine/about/divisions/nhli/respiration/pop
genetics/reph/
Opinions expressed are those of the author, not of the institution.
------------------------------------------------------------------------
---------------------
package rsource from http://www.imperial.ac.uk/nhli/r.newson/stata10
------------------------------------------------------------------------
---------------------
TITLE
rsource: Run R from inside Stata using an R source file
DESCRIPTION/AUTHOR(S)
The program rsource runs the Rterm command of R from inside
Stata,
using an R source file, if R is installed on the user's system.
The output and/or the source file can be listed to the Stata log
file
and/or to the Stata Results window in an interactive Stata
session.
If the R directory on the user's system is not on the user's
default
path, then the user must set the global macro Rterm_path to
contain
the path for the Rterm command, possibly in the profile.do file
(see on-line help for details).
Author: Roger Newson
Distribution-Date: 02december2008
Stata-Version: 10
INSTALLATION FILES (click here to
install)
rsource.ado
rsource.sthlp
------------------------------------------------------------------------
---------------------
(click here to return to the previous screen)
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/