# shiftdim

Version:

Shifts the dimensions of an array.

## Syntax

b = shiftdim(a, n)
[b, nd] = shiftdim(a)

## a

Array of any dimension.

## n

Positions to shift. n must be an integer scalar. If n is a positive value, shiftdim shifts the dimensions of a to the left. If n is a negative value, shiftdim shifts the dimensions of a to the right.

## nd

Number of dimensions removed. If you use shiftdim with one parameter, the function removes the leading singleton dimensions.

## b

a with shifted dimensions.

Where This Node Can Run:

Desktop OS: Windows

FPGA: This product does not support FPGA devices