Skip to Main Content Skip to Search
Product Documentation

iptnum2ordinal - Convert positive integer to ordinal string

Syntax

string = iptnum2ordinal(number)

Description

string = iptnum2ordinal(number) converts the positive integer number to the ordinal text string string.

Examples

The following example returns the string 'fourth'.

str = iptnum2ordinal(4)

The following example returns the string '23rd'.

str = iptnum2ordinal(23)
  


Recommended Products

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.

 © 1984-2012- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS