Skip to content

__rotdim__

general · scripts/general/__rotdim__.m

: y = rotdim (x)
: y = rotdim (x, n)
: y = rotdim (x, n, plane)

Rotate the array x counter-clockwise by n quarter turns (default 1) in the plane spanned by the two dimensions in plane.

By default the plane is formed by the first two non-singleton dimensions. Negative n rotates clockwise. For matrices the result equals rot90 (x, n).