Re: [Rcpp-devel] Matrix assignment with inline

2010-11-04 Thread Kaveh Vakili
Thanks for the advice Dirk, > >Kaveh, > >If you are having problems with things like matrix indexing I would recommend >a somewhat more incremental approach: > > pass a matrix from R, find the maximum element and return it > > pass a matrix from R, find the min and maximum elements and

Re: [Rcpp-devel] Matrix assignment with inline

2010-11-04 Thread Dirk Eddelbuettel
Kaveh, If you are having problems with things like matrix indexing I would recommend a somewhat more incremental approach: pass a matrix from R, find the maximum element and return it pass a matrix from R, find the min and maximum elements and return both multiply two (small) ma

Re: [Rcpp-devel] Matrix assignment with inline

2010-11-04 Thread Romain Francois
Le 03/11/10 12:16, Kaveh Vakili a écrit : Hi list, I'm trying to learn inline by translating snippets of c++ code from the book "Numerical Recipes". in page 44-45, there is a c++ code to perform Gauss-Jordan elimination of a matrix (see below). I understand that they have a large template of a

[Rcpp-devel] Matrix assignment with inline

2010-11-04 Thread Kaveh Vakili
Hi list, I'm trying to learn inline by translating snippets of c++ code from the book "Numerical Recipes". in page 44-45, there is a c++ code to perform Gauss-Jordan elimination of a matrix (see below). I understand that they have a large template of additional operator/function/class (it is o