[問題] 用system功能送job給cluster

看板R_Language作者 (..)時間6年前 (2017/09/14 20:58), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串1/2 (看更多)
[問題敘述]: 我有個R script長這樣 檔名是 Rcode.r 裡面包含 system (paste ("qsub /path/test.sh", sep=""), ignore.stdout=T, wait=T ) q("no") 我想使用這個 R script 送 shell script job 給 cluster 執行 我在 terminal 畫面打上 $ rR Rcode.r 執行後卻出現 sh: qsub: command not found 的錯誤訊息 當我在terminal進入R畫面 直接打上一樣的 R script > system (paste ("qsub /path/test.sh", sep=""), ignore.stdout=T, wait=T ) 我卻可以成功把job送出去 並且執行完成 我確定當我打$ qsub test.sh terminal可以正常的送job出去 但當我透過R 用system這功能送job時 卻回覆command not found的錯誤 為什麼會這樣呢?? ps. 我也試過 system (paste ("/usr/torque/bin/qsub /path/test.sh", sep=""), ignore.stdout=T, wait=T ) 但一樣出現 sh: /usr/torque/bin/qsub: No such file or directory [程式範例]: [環境敘述]: [關鍵字]: 選擇性,也許未來有用 -- ※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 130.225.0.251 ※ 文章網址: https://www.ptt.cc/bbs/R_Language/M.1505393910.A.1B3.htmlhkopee123:轉錄至看板 Linux 09/14 21:11
文章代碼(AID): #1Pkdps6p (R_Language)
文章代碼(AID): #1Pkdps6p (R_Language)