Is Rcpp compatible with rpy2?
I would like to call a very complex R function from python. My function
depends on code implemented with Rcpp. When I try to load Rcpp from python
via

import rpy2.robjects as robjects
robjects.r('library(Rcpp)')

I get the following:

Error in dyn.load(file, DLLpath = DLLpath, ...) :
  unable to load shared object
'/home/jonas/R/x86_64-unknown-linux-gnu-library/2.13/Rcpp/libs/Rcpp.so':
  /home/jonas/R/x86_64-unknown-linux-gnu-library/2.13/Rcpp/libs/Rcpp.so:
undefined symbol: R_ClassSymbol
Error: package/namespace load failed for 'Rcpp'
Traceback (most recent call last):
  File "RcppTest.py", line 2, in <module>
    robjects.r('library(Rcpp)')
  File
"/usr/local/lib/python2.7/dist-packages/rpy2-2.2.2dev_20110811-py2.7-linux-x86_64.egg/rpy2/robjects/__init__.py",
line 225, in __call__
    res = self.eval(p)
  File
"/usr/local/lib/python2.7/dist-packages/rpy2-2.2.2dev_20110811-py2.7-linux-x86_64.egg/rpy2/robjects/functions.py",
line 82, in __call__
    return super(SignatureTranslatedFunction, self).__call__(*args,
**kwargs)
  File
"/usr/local/lib/python2.7/dist-packages/rpy2-2.2.2dev_20110811-py2.7-linux-x86_64.egg/rpy2/robjects/functions.py",
line 34, in __call__
    res = super(Function, self).__call__(*new_args, **new_kwargs)
rpy2.rinterface.RRuntimeError: Error: package/namespace load failed for
'Rcpp'

>From what I understand R_ClassSymbol is supplied by libR.so, which should by
loaded by rpy2 anyway in order to work at all, or am I totally wrong here?

Running python 2.7.1, rpy2-2.2.2, R 2.13.0
I would appreciate any help.

Regards,
Jonas
_______________________________________________
Rcpp-devel mailing list
Rcpp-devel@lists.r-forge.r-project.org
https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel

Reply via email to