Любая помощь будет принята с благодарностью.
Я пытаюсь запустить скрипт R внутри Python, используя rpy2.
#Import robjects from rpy2
import rpy2.robjects as robjects
#Running r script from source
r_source = robjects.r['source']
r_source('Forecast.R')
Когда я бегу, я получаю сообщение об ошибке:
RRuntimeError Traceback (most recent call last)
<ipython-input-12-ca3214430c3e> in <module>()
1 #Running r script from source
2 r_source = robjects.r['source']
----> 3 r_source('Forecast.R')
~\Anaconda3\lib\site-packages\rpy2-2.9.1-py3.6-win-amd64.egg\rpy2\robjects\functions.py in __call__(self, *args, **kwargs)
176 v = kwargs.pop(k)
177 kwargs[r_k] = v
--> 178 return super(SignatureTranslatedFunction, self).__call__(*args, **kwargs)
179
180 pattern_link = re.compile(r'\\link\{(.+?)\}')
~\Anaconda3\lib\site-packages\rpy2-2.9.1-py3.6-win-amd64.egg\rpy2\robjects\functions.py in __call__(self, *args, **kwargs)
104 for k, v in kwargs.items():
105 new_kwargs[k] = conversion.py2ri(v)
--> 106 res = super(Function, self).__call__(*new_args, **new_kwargs)
107 res = conversion.ri2ro(res)
108 return res
RRuntimeError: Error in library(RODBC) : there is no package called 'RODBC'