Can't call cygwin commands from R

前端 未结 1 1685
忘了有多久
忘了有多久 2021-01-07 15:01

I\'m working in windows box, and using cygwin to imitate unix shell. Also I have R and want to run any system comand from it. I believe that system(\'command\')

相关标签:
1条回答
  • 2021-01-07 15:36

    I hope you are still interested in a solution. Here is what I have:

    • Start R from Windows and call cygwin executable by path: system('C:/cygwin/bin/ls.exe');
    • Start R from within cygwin:
      • Start cygwin
      • Set path: export PATH="$PATH:/cygdrive/c/Programme/R-2.9.2/bin"
      • Call R: Rgui.exe
      • Call shell: system('ls')

    Regards,

    Martin.

    0 讨论(0)
提交回复
热议问题