flipdim
Flip an array along the specified dimension.
(y)=flipdim(x,n)
Inputs
x An array.
n An integer that specifies the dimension along which the array should be flipped.
Outputs
y The result of flipping the dimension.


Description
If m is the size of x along the dimension n ,
    y[:,:,..,i,....]=x[:,:,..,m-i+1,....]
where i and m-i+1 are the indices along the n'th dimension.




Example
>>a=fix(100randn(2,3,4))
>>a
[:,1:3, 1]
          220         -171            8
           -3          -90         -145
[:,1:3, 2]
           17          130           87
           93          136           28
[:,1:3, 3]
            2           71          142
         -121          -12          144
[:,1:3, 4]
          -44           -4          -98
         -225         -161          -61

>>flipdim(a,3)
[:,1:3, 1]
          -44           -4          -98
         -225         -161          -61
[:,1:3, 2]
            2           71          142
         -121          -12          144
[:,1:3, 3]
           17          130           87
           93          136           28
[:,1:3, 4]
          220         -171            8
           -3          -90         -145