diff matlab doc code example
Example: diff(x) matrix matlab
X = [1 3 5;7 11 13;17 19 23];
Y = diff(X,1,2)
Y = 3×2
ans:
2 2
4 2
2 4
X = [1 3 5;7 11 13;17 19 23];
Y = diff(X,1,2)
Y = 3×2
ans:
2 2
4 2
2 4