Sort character vectors containing embedded numbers in natural numeric
order rather than lexicographic order. For example, "c1g2" comes before
"c1g10", which standard sort() would not guarantee.
Details
The function extracts all numeric segments from each string using
stringr::str_extract_all() and sorts by them sequentially (first
number, then second). Designed for two-segment identifiers such as
"c1g1", "c2g10", etc.
See also
sort() for standard lexicographic sorting.
