Thank you Simon for suggesting pointer then dereferencing it later in class methods.
Dirk also suggested using matrix views which may have the same performance while keeping syntax neat. Will repost both working solution later on for the record. Thanks again, I found all suggestion very helpful, Steven On Nov 26, 2013 6:19 AM, <szehn...@uni-bonn.de> wrote: > Steve, > > If you want to use a variable being an arma::mat obejct with varying > memory, you could use an arma::mat pointer. Otherwise if memory stays the > same but should be reusable in R, Dirk's suggestion initialising memory in > R and passing it to C++ is the most practicable way and very fast. > > Best > Simon > Gesendet über den BlackBerry® Service von E-Plus. > > -----Original Message----- > From: Steven Varga <steven.va...@gmail.com> > Sender: rcpp-devel-bounces@lists.r-forge.r-project.orgDate: Mon, 25 Nov > 2013 23:23:24 > To: <rcpp-devel@lists.r-forge.r-project.org> > Reply-To: steven.va...@gmail.com > Subject: Re: [Rcpp-devel] RcppArmadillo matrix with writeable auxiliary > memory > > _______________________________________________ > Rcpp-devel mailing list > Rcpp-devel@lists.r-forge.r-project.org > https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel >
_______________________________________________ Rcpp-devel mailing list Rcpp-devel@lists.r-forge.r-project.org https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel