Documentation

This is machine translation

Translated by Microsoft
Mouse over text to see original. Click the button below to return to the English verison of the page.

isrow

Determine whether input is row vector

Syntax

isrow(V)

Description

isrow(V) returns logical 1 (true) if size(V) returns [1 n] with a nonnegative integer value n, and logical 0 (false) otherwise.

Examples

Determine if a vector is a row. This example is a column so isrow returns 0:

V = rand(5,1);
isrow(V)
ans =
     0

Transpose the vector to make it a row. isrow returns 1:

V1 = V';
isrow(V1)
ans =
     1

More About

collapse all

Tall Array Support

This function fully supports tall arrays. For more information, see Tall Arrays.

Was this topic helpful?