[Rcpp-devel] How to use sourceCpp() to call a file with '.hpp'

2017-01-19 Thread Kokia Z
I have found a .hpp file called fn_kron.hpp, and I have learned that sourceCpp() can be used to call c++ file to R. But when I wrote in this way, it returned the filename must be '.cpp', so how could I use sourceCpp to call this package? Thanks for your help. :)___

[Rcpp-devel] Problem with calling a function in RcppArmadillo to R

2016-11-18 Thread Kokia Z
I need to compute a kronecker product of two matrix, but the vector is out of the limit: Error in kronecker(X, as(Y, "TsparseMatrix"), FUN = FUN, make.dimnames = make.dimnames, : Error in validityMethod(as(object, superClass)) : no support for long vectors:../include/Rinlinedfuns.h:137