This now works with Row and Col too, as in :
test.armadillo.sugar.ctor <- function(){
fx <- cxxfunction( signature(x= "numeric") , '
NumericVector xx(x) ;
arma::mat m = xx + xx ;
arma::colvec co = xx ;
arma::rowvec ro = xx ;
return List::create(
After some discussion this morning with Conrad (who develops Armadillo),
we've come up with a way that is not too intrusive on armadillo itself
(it adds about 6 lines of code), yet opens a door for RcppArmadillo to
adds its own constructors to the Mat template class.
I've added this one now :
Le 18/08/10 06:56, Davor Cubranic a écrit :
On August 17, 2010 03:26:15 am Romain Francois wrote:
After the last thread, I looked again at armadillo and came up with a
way to make it aware of Rcpp sugar, so that we can create an
armadillo matrix from an Rcpp sugar expression, without having to
a
On August 17, 2010 03:26:15 am Romain Francois wrote:
> After the last thread, I looked again at armadillo and came up with a
> way to make it aware of Rcpp sugar, so that we can create an
> armadillo matrix from an Rcpp sugar expression, without having to
> assign the expression into an Rcpp vecto
Le 17/08/10 13:36, Dirk Eddelbuettel a écrit :
On 17 August 2010 at 12:26, Romain Francois wrote:
| Hello,
|
| After the last thread, I looked again at armadillo and came up with a
| way to make it aware of Rcpp sugar, so that we can create an armadillo
| matrix from an Rcpp sugar expression, wi
On 17 August 2010 at 12:26, Romain Francois wrote:
| Hello,
|
| After the last thread, I looked again at armadillo and came up with a
| way to make it aware of Rcpp sugar, so that we can create an armadillo
| matrix from an Rcpp sugar expression, without having to assign the
| expression into