[Rcpp-devel] variable affectation in Rcpp Rcpp Armadillo
nh269 at cornell.edu
Thu Jun 16 05:57:33 CEST 2011
I finally figured out, it was a syntax error, as the new assigned object was
not an arma:: mat but an element from a list
I took care of the problem by using ui = Rcpp::as<arma::mat>(all_ui[i]) in
Thank you again all for your help
On Wed, Jun 15, 2011 at 11:00 PM, Dirk Eddelbuettel <edd at debian.org> wrote:
> On 15 June 2011 at 20:17, Nicolas Heslot wrote:
> | Any idea about this variable reaffectation thing?
> Well ... that still make little sense. Variables are not protected; there
> nothing stopping you from re-assigning values, be it element-wise, row or
> column-wise, or as a whole matrix. So I suspect you have a simple syntax
> But as you still have not shown an actualy error it remains idle
> on our side.
> | It seems to be specific to arma classes like arma::mat
> Not really. We all use these and read values from / assign values into at
> will. There are numerous examples in the archives of this mailing list, in
> the unit tests, and in some of the slides from past presentations.
> Gauss once played himself in a zero-sum game and won $50.
> -- #11 at http://www.gaussfacts.com
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Rcpp-devel