Re: [Rd] .Call - applying setAttrib(x, R_DimSymbol, s) to a matrix being an element of a list

From: Simon Urbanek <>
Date: Wed 16 Mar 2005 - 18:01:46 GMT


you gave us only a fragment of your code, so I can only guess what the problem is:

On Mar 16, 2005, at 12:40 PM, Oleg Sklyar wrote:

> // converting element into a matrix
> setAttrib(element, R_DimSymbol, imgSize);

What is imgSize? The behavior you describe seems as if you re-using the imgSize SEXP in all elements. AFAIR in your case setAttrib doesn't copy the value, so you need to do so yourself (or alloc new dim array for each element).

Simon mailing list Received on Thu Mar 17 05:04:24 2005

This archive was generated by hypermail 2.1.8 : Mon 20 Feb 2006 - 03:21:02 GMT