iptnum2ordinal
Convert positive integer to ordinal character vector
Description
Examples
Convert Integers to Ordinal Numbers
Convert the number 4 to an ordinal number. The ordinal number is spelled out in entirety.
str = iptnum2ordinal(4)
str = 'fourth'
Convert the number 23 to an ordinal number. The ordinal number consists of a
numeral and the ordinal suffix 'rd'
.
str = iptnum2ordinal(23)
str = '23rd'
Input Arguments
Output Arguments
Version History
Introduced before R2006a