3/14/2024 0 Comments Matlab reshapeHmmm wait a minute the dimension of size 20 is no longer the original dimension of size 20, maybe rearranging my original dimensions will affect this. So far so good until I plot a pixel and its time values plot(, squeeze(twoD1(962400,:))) This is how one voxel ove time looks plot(, squeeze(array1(200,200,:,12))) ![]() I know (or thought I knew) how to do this and have tried every possible order of dimensions prior to reshaping, but none result in my old data: array1 = rand(400,400,20,24) I have to do an operation on each voxel and to make this quicker I want to reshape my array into a 2D matrix where one dimension is 20 and only has the time values. I have a 400x400x20x24 array in which 400x400 is an image and 24 is a number of images at 20 times. However I have tried every position for my time dimension possible and for me right now reshaping and keeping one dimension the same does not work: So I have found many questions and answers about this on SO already and I think my approach should work as it is not very complicated.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |