"Here's the command:"
Works for me. Try sourcing the attached file (which includes your
command, +verbose=T), and post back the *full* results, including the
source('tmp.R.txt') command and the next prompt line.
-christian
--
A man, a plan, a cat, a ham, a yak, a yam, a hat, a canal – Panama!
require(inline)
src <- '
Rcpp::NumericVector xa(a);
Rcpp::NumericVector xb(b);
int n_xa = xa.size(), n_xb = xb.size();
Rcpp::NumericVector xab(n_xa + n_xb - 1);
for (int i = 0; i < n_xa; i++)
for (int j = 0; j < n_xb; j++)
xab[i + j] += xa[i] * xb[j];
return xab;
'
fun <- cxxfunction( signature(a="numeric", b="numeric"), src, plugin="Rcpp",
verbose=TRUE)
_______________________________________________
Rcpp-devel mailing list
[email protected]
https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel