1
嗨,我只是下載rpy2和Python 2.6。當我嘗試運行一些我在互聯網上找到的示例代碼時,我得到了這個錯誤。任何人都可以解釋爲什麼會發生這種情況,我該如何解決它?謝謝。如何設置rpy2?
import rpy2.robjects as RO
Traceback (most recent call last):
File "<pyshell#0>", line 1, in <module>
import rpy2.robjects as RO
File "C:\Python26\lib\site-packages\rpy2\robjects\__init__.py", line 12, in <module>
import rpy2.rinterface as rinterface
File "C:\Python26\lib\site-packages\rpy2\rinterface\__init__.py", line 22, in <module>
"This might be because R.exe is nowhere in your Path.")
RuntimeError: Unable to determine R version from the registery.Calling the command 'R RHOME' does not return anything.
This might be because R.exe is nowhere in your Path.
此頁面描述如何設置路徑:http://www.computerhope.com/issues/ch000549.htm – SiggyF 2010-07-31 22:53:41