Calling R script from python using rpy2

断了今生、忘了曾经 提交于 2019-11-27 18:02:48

source is a r function, which runs a r source file. Therefore in rpy2, we have two ways to call it, either:

r['source']("script.R")

or

r.source("script.R")

r[r.source("script.R")] is a wrong way to do it.

Same idea may apply to the next line.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!