Reputation: 1443
I've found a lot of answers on how to run R from a Batch file, but nothing about running a Batch File from R. I know one way to do this is to use system
, system2
or shell
, but these methods wait for process in the Windows Command Prompt to finish before R accepts another input. I want to run a Batch File which calls a console application that runs indefinitely, and then allow R to do other things. Any help would be greatly appreciated.
Upvotes: 0
Views: 1853
Reputation: 37641
The help page ?shell
says how to do it. Just run
shell("MyScript.bat", wait=FALSE)
Upvotes: 2