[Rcpp-devel] using Rinside/Rcpp and Eigen
edd at debian.org
Thu Apr 12 17:51:53 CEST 2012
Thanks for posting here.
On 12 April 2012 at 07:31, Cattus Cerebrum wrote:
| I have a c++ project that stores data in Eigen matrices.
| I would like to use R functionality from the c++ code,
| but I am not sure how to convert my data to Rcpp data types
| (e.g. NumericVector). Should I create a NumericVector
| and copy my data into it, or is there any way to avoid the
| copy by using the common storage? Eigen matrix has a method
| data() that returns the underlying double pointer, and
| methods that give outer and inner strides of the matrix.
Take a look at the RcppEigen package and its code.
R/Finance 2012 Conference on May 11 and 12, 2012 at UIC in Chicago, IL
See agenda, registration details and more at http://www.RinFinance.com
More information about the Rcpp-devel