Natural Ordering

Provides functions related to human natural ordering. It handles adjacent digits in a character sequence as a number so that natural sort function arranges a character vector by their numbers, not digit characters. It is typically seen when operating systems lists file names. For example, a sequence a-1.png, a-2.png, a-10.png looks naturally ordered because 1 < 2 < 10 and natural sort algorithm arranges so whereas general sort algorithms arrange it into a-1.png, a-10.png, a-2.png owing to their third and fourth characters.


News

Version 0.1.2

  • [update] Includes the LICENSE file in the package.
  • [bugfix] Fixes tests.

Version 0.1.1

  • [bugfix] Returns several NAs when argument is just one element (#1)
  • [bugfix] Produces an error when all elements are empty character (#2)
  • [bugfix] Produces an error when input is empty (#3)

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.

install.packages("naturalsort")

0.1.3 by Kosei Abe, 3 years ago


Report a bug at https://github.com/kos59125/naturalsort/issues


Browse source code at https://github.com/cran/naturalsort


Authors: Kosei Abe


Documentation:   PDF Manual  


BSD_3_clause + file LICENSE license


Suggests testthat


Imported by castor, corehunter, james.analysis.


See at CRAN