Error using reshape To RESHAPE the number of elements must not change.

1 view (last 30 days)
Can someone help me with this error. I attempted to use numel to fix it but was not able to get a clear response.
  2 Comments
Ameer Hamza
Ameer Hamza on 24 May 2020
The error message is quite self-descriptive. The product of ngx*ngy*ngz should be equal to numel(v). In your case, matrix v must have 30^3 = 27000 elements.

Sign in to comment.

Answers (0)

Categories

Find more on Resizing and Reshaping Matrices in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!