MATLAB: How to find the difference between 2 consecutive rows of a matrix

Hello all,
I have a (165475 x 2) matrix and I would like to find the difference between any two consecutive rows and store them in a new matrix. Can anybody help me? Thanks.

Best Answer

diff(A)