Main Content
isordinal
Determine if input is ordinal categorical array
Syntax
Description
tf = isordinal(
returns logical
A
)1
(true
) if the input is an ordinal
categorical array. Otherwise, isordinal
returns logical
0
(false
).
If a categorical array is ordinal, you can use relational operations for inequality comparisons, such as greater than and less than, in addition to tests for equality.
Examples
Input Arguments
Tips
To convert a categorical array,
A
, from nonordinal to ordinal, useA = categorical(A,Ordinal=true)
.To convert a categorical array,
A
, from ordinal to nonordinal, useA = categorical(A,Ordinal=false)
.