MATLAB: Hello,How ı should chose desired columns in a row in matrix?Thanks

matrixrows and colums

A=[1 2 3 4 5; 4 5 6 7 8; 7 8 9 9 5] I want a matrix which should consist of columns from 2 to 5 except 4 in 2nd row of A.

Best Answer

out = A(:,2:5)