How to make a "page transpose" in a 3D matrix without using the function pagetranspose?

7 views (last 30 days)
Sim
Sim on 10 Feb 2022
Commented: Sim on 13 Feb 2022
How to make a "page transpose" in a 3D matrix without using the function pagetranspose (due to older version of matlab)?

Accepted Answer

James Tursa
James Tursa on 10 Feb 2022
Mtranspose = permute(M,[2 1 3]);

More Answers (1)

David Hill
David Hill on 10 Feb 2022
for k=1:size(yourMatrix,3)
newMatrix(:,:,k)=yourMatrix(:,:,k)';
end

Community Treasure Hunt

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

Start Hunting!