MATLAB: How to truncate specific rows and columns of matrix in matlab.

A = [10,20,30,40; ...
20,30,40,50; ...
30,40,50,60; ...
40,50,60,70];
now i want to truncate the row no 2 and col no 2 and wants to get new matrix of 3×3? kindly help me

Best Answer

A(2,:)=[]
A(:,2)=[]