Storing a 2D array in a 1d Dataset

All,

I have created an 2d array datatype ( for a 4X4 matrix ) and I want to
store this in a one dimensional dataset along with few more data . I am
passing a 4X4 array as input for writing into this element but the
value written is wrong . Is there a way of doing this correctly or
should I use only a 2D dataset for this purpose ?

Regards

Ram

Ram,

It is hard to say what is going wrong, but you should be able to create a one-dimensional array of 2x2 arrays elements.

Here is an example in C how one can do it http://www.hdfgroup.uiuc.edu/UserSupport/code-examples/h5_array_type0.c I hope it will help.

Elena

ยทยทยท

On May 20, 2008, at 4:41 AM, Ramakrishnan Iyer wrote:

All,

I have created an 2d array datatype ( for a 4X4 matrix ) and I want to store this in a one dimensional dataset along with few more data . I am passing a 4X4 array as input for writing into this element but the value written is wrong . Is there a way of doing this correctly or should I use only a 2D dataset for this purpose ?

Regards

Ram