[R] Running other programs from R

David Winsemius dwinsemius at comcast.net
Sun Mar 17 19:36:38 CET 2013


On Mar 16, 2013, at 2:09 PM, Sedat Sen wrote:

> Dear list,
> 
> I want to run a statistical program (using its .exe file)  from R  by
> writing a script. I know there are some packages that call WinBUGS, Mplus
> etc. form R. I just want to call the .exe extension of this program and run
> several times writing a code in R. Thus, I want to have the output inside R.
> 
> I just don't know where to start. Does anyone have any idea about that? Is
> there a universal package to call application files of other stat programs
> using their application files.
> 
> p.s. The program I am talking about is an IRT program called Multilog.

Even though you have been advised to use system() I don't think that will necessarily return your values "inside R". You will need to supply arguments to that external function and direct it to write to a file from which you can extract its output using text processing in R. You will probably need to examine the (open source) methods used by packages that call those external programs if you demand the same level of integration as provided for example in the R2WinBUGS package.

> 	[[alternative HTML version deleted]]

Please read the Posting Guide.

-- 
David Winsemius
Alameda, CA, USA



More information about the R-help mailing list