Learn R Programming

name (version 0.0.2)

sort_phrase: Sort by Phrase

Description

Sort by Phrase

Usage

sort_phrase(x, loc = 2)

Value

character

Arguments

x

character; strings to sort

loc

number of location to sort by. For example 1_2_3_4 with loc = 3 sorts by 3.

Examples

Run this code
x <- c('pop_2020_est', 'pop_white_2020', 'pop_black_2020', 'pop_white_2021')
sort_phrase(x)

Run the code above in your browser using DataLab