2017-02-17 42 views
0

我正在嘗試查看是否可以在我的用戶帳戶中運行代碼示例,而不是在testuser帳戶中運行。爲此,我做了以下內容:腳本測試似乎沒有正確的工作目錄

當我這樣做,我得到的錯誤:

Connecting to 172.31.232.190:8000 
3:53:26 PM Stream Connect matthew.pettis connection established, waiting for an event... 
> require(deployrUtils) 
> deployrInput("{\"name\": \"bal\", \"render\":\"integer\", \"default\": 5000, \"min\" : 0, \"max\": 25000 }") 
> deployrInput("{\"name\": \"trans\", \"render\":\"integer\", \"default\": 12, \"min\" : 0, \"max\": 100 }") 
> deployrInput("{\"name\": \"credit\", \"render\":\"integer\", \"default\": 8, \"min\" : 0, \"max\": 75 }") 
> if (!exists("fraudModel")) { 
+ load("fraudModel.rData") 
Console Error cannot open the connection 
API Error cannot open the connection 

我試圖在這裏下列崗位來解決,但我找不到在我的目錄是:deployR cannot open the connection

當我使用腳本來尋​​找工作目錄(和列表內容),我看到:

> require(deployrUtils) 
> getwd() 
[1] "C:/PROGRA~1/MICROS~2/DEPLOY~1.0/rserve/workdir/conn2209460" 
> list.files(getwd()) 
[1] "DeployREngineSource.r" "unnamedplot001.png" 

這似乎是錯誤的直接tory被使用。當我嘗試爲我的用戶尋找我的目錄時,我似乎無法找到它。我的DeployR版本是8.0.0。

幫助表示讚賞。

謝謝, 馬特

回答

0

是遠程目錄(第二個框)? 如果是這樣,你爲什麼不叫setwd()