Project

General

Profile

Transfer a 3D field to a 1D vector

Added by Philippe Lucas-Picher about 4 years ago

Hello,

I would like to know if there is a way to transfer a 3(x) per 3(y) per 3(t) field to a single vector of 81 values ?
In other words, I would like to take a 3x3x3 field of precipitation let say and transfer it in a single vector of 81 values.
In an another way, I just want to align all the values of a 3D field into a single column.

Thank you for your help
Philippe


Replies (1)

RE: Transfer a 3D field to a 1D vector - Added by Ralf Mueller about 4 years ago

hi Philippe!

I think I would use XArray for this or numpy.reshape(). You cannot do it with CDO because it's not CF-compatible.

hth
ralf

    (1-1/1)