Navigation

Operators and Keywords

Function List:

C++ API

: ndims (a)

Return the number of dimensions of a.

For any array, the result will always be greater than or equal to 2. Trailing singleton dimensions are not counted.

ndims (ones (4, 1, 2, 1))
   ⇒ 3

See also: size.

Package: octave