Hello everyone. I am currently working with a matrix read from a .nc file. This matrix has dimensions of 361x201x50x31. I need to send this matrix to a code which is designed to deal with matrices of order 50x361x201x31, so I need to rearrange the matrix using the new dimensions.
I have attempted to follow these instructions, but I get an error telling me that the resize function isn't found in my computer.
I have also attempted to use dim, but if I write
rdim(dataECMWF_U)<-c(50, 361, 201, 31) , then if I compare the original values evaluated at (a,b,c,d) with the values of the new matrix evaluated at (c,a,b,d), I don't get the same values, so I don't think that is the correct answer to my problem.
Can someone please offer me advice on how to proceed?
Thanks in advance.