isrow - Determine if input is row vector - MATLAB (original) (raw)

Main Content

Determine if input is row vector

Syntax

Description

`tf` = isrow([V](#mw%5Faacabd8d-c588-4d67-b528-279b83b91cb3)) returns logical 1 (true) if V is a row vector. Otherwise, it returns logical 0 (false). A row vector is a two-dimensional array that has a size of 1-by-N, where N is a nonnegative integer.

example

Examples

collapse all

Create a vector. Determine if it is a row vector.

V = rand(5,1); tf = isrow(V)

Find the conjugate transpose of the vector. Determine if it is a row vector.

Create a scalar, which is a 1-by-1 array.

Determine if the scalar V is also a row vector.

Create an array of characters. Determine if it is a row vector.

V = 'Hello, World!'; tf = isrow(V)

Check the dimension of V by using size. V is a 1-by-13 character vector, which is also a row vector.

Now create a string scalar by enclosing a piece of text in double quotes.

Check if the scalar V is also a row vector.

Input Arguments

collapse all

Input array, specified as a scalar, vector, matrix, or multidimensional array.

Algorithms

Extended Capabilities

expand all

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

The isrow function fully supports GPU arrays. To run the function on a GPU, specify the input data as a gpuArray (Parallel Computing Toolbox). For more information, see Run MATLAB Functions on a GPU (Parallel Computing Toolbox).

Version History

Introduced in R2010b