Re: [Rd] double pointer matrix

2006-03-08 Thread Hin-Tak Leung
CC-ing r-devel for the direct e-mail. Bernd Kriegstein wrote: > Hi Hin-Tak, > > Thanks for the answer, but it's a little bit > tangential. Mind you that y is a double pointer, > commonly used in initialization of matrices. My > problem is that I cannot eventually access the > elements of this mat

Re: [Rd] double pointer matrix

2006-03-07 Thread Hin-Tak Leung
Please don't do malloc inside C code like this - it won't interact too well with the garbage collector in R, and your program probably will either leak or crash or both... and when are you going to do your free()? What you want is do is to delete that malloc line and do the allocation on the R s