Grocer Function

NAME

tdiff - produce matrix differences

CALLING SEQUENCE

[dmat]=tdiff(x,k)

PARAMETERS

Input

Output

DESCRIPTION

Produces matrix differences.

EXAMPLE

1) x1=ones(7,1);x2=[1:7]';y = tdiff([x1 x2],2)
2) dep = tdiff(r,1);

Example 1 gives the matrix:
!   0.    0. !
!   0.    0. !
!   0.    2. !
!   0.    2. !
!   0.    2. !
!   0.    2. !
!   0.    2. !
In example 2, taken from cadf, vector r is differenciated once.

AUTHOR

Eric Dubois 2002