diff¶
diff computes differences such as the following: [x[2] - x[1], x[3] - x[2], … , x[n] - x[n-1]]
- rmDiff = diff(rmMat)
Return Value
rmDiff is a difference matrix or a vector.
Parameters
- r
rmMat is a real matrix or a vector.
Example
* a = [1,2,5,4,5,6]
* diff(a)
1 3 -1 1 1
See also
id-273623