开发者

Rpy2 error: "No module named _rinterface"?

I开发者_Python百科 am getting the following error when trying to load rpy2:

>>> from rpy2 import robjects
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "C:\Python26\lib\site-packages\rpy2\robjects\__init__.py", line 14, in <m
odule>
    import rpy2.rinterface as rinterface
  File "C:\Python26\lib\site-packages\rpy2\rinterface\__init__.py", line 78, in
<module>
    from rpy2.rinterface._rinterface import *
ImportError: No module named _rinterface

I'm using R 2.11.1, Python 2.6.5, and rpy2 2.2.2.0.

Any ideas?


I believe the issue is that rinterface is having trouble locating R on your box. In unix, you can solve this by updating the bashrc profile (typically located at /etc/bashrc). There, you'd add a line like this: LD_LIBRARY_PATH=/path/to/R

There must be something similar in windows...

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜