Functions
── Attaching packages ─────────────────────────────────────── tidyverse 1.3.1 ──
✔ ggplot2 3.3.5 ✔ purrr 0.3.4
✔ tibble 3.1.4 ✔ dplyr 1.0.7
✔ tidyr 1.1.4 ✔ stringr 1.4.0
✔ readr 2.0.2 ✔ forcats 0.5.1
── Conflicts ────────────────────────────────────────── tidyverse_conflicts() ──
✖ dplyr::filter() masks stats::filter()
✖ dplyr::lag() masks stats::lag()
tb <- read_csv("data/tb_long.csv")
Rows: 201 Columns: 18
── Column specification ────────────────────────────────────────────────────────
Delimiter: ","
chr (1): country
dbl (15): year, m014, m1524, m2534, m3544, m4554, m5564, m65, f014, f1524, f...
lgl (2): mu, fu
ℹ Use `spec()` to retrieve the full column specification for this data.
ℹ Specify the column types or set `show_col_types = FALSE` to quiet this message.
tb_tidy <- tb %>%
pivot_longer(starts_with(c('m', 'f')))
tb_tidy
# A tibble: 3,216 × 4
country year name value
<chr> <dbl> <chr> <dbl>
1 AD 2000 m014 0
2 AD 2000 m1524 0
3 AD 2000 m2534 1
4 AD 2000 m3544 0
5 AD 2000 m4554 0
6 AD 2000 m5564 0
7 AD 2000 m65 0
8 AD 2000 mu NA
9 AD 2000 f014 NA
10 AD 2000 f1524 NA
# … with 3,206 more rows
tb_tidy <- tb_tidy %>%
separate(name, into = c("sex", "age_group"), sep = 1)
tb_tidy
# A tibble: 3,216 × 5
country year sex age_group value
<chr> <dbl> <chr> <chr> <dbl>
1 AD 2000 m 014 0
2 AD 2000 m 1524 0
3 AD 2000 m 2534 1
4 AD 2000 m 3544 0
5 AD 2000 m 4554 0
6 AD 2000 m 5564 0
7 AD 2000 m 65 0
8 AD 2000 m u NA
9 AD 2000 f 014 NA
10 AD 2000 f 1524 NA
# … with 3,206 more rows
tb_tidy %>%
distinct(age_group)
# A tibble: 8 × 1
age_group
<chr>
1 014
2 1524
3 2534
4 3544
5 4554
6 5564
7 65
8 u
Breakdown the problem
[1] TRUE
str_sub("014", start = 1, end = 1)
[1] "0"
str_sub("014", start = 2, end = -1)
[1] "14"
Partial solution
clean_age_group <- function(age_group_string) {
if (age_group_string == "u") {
return("Unknown")
}
}
[1] "Unknown"
clean_age_group("u") == "Unknown"
[1] TRUE
Complete solution
clean_age_group <- function(age_group_string) {
if (age_group_string == "u") {
return("Unknown")
} else if (str_starts(age_group_string, "0")) {
age_cat = paste0(str_sub(age_group_string, start = 1, end = 1), "-", str_sub(age_group_string, start = 2, end = -1))
return(age_cat)
} else if (age_group_string == "65") {
return("65+")
} else if (str_length(age_group_string) == 4) {
age_cat = paste0(str_sub(age_group_string, start = 1, end = 2), "-", str_sub(age_group_string, start = 3, end = -1))
return(age_cat)
}
}
[1] 3
Test your code
stopifnot(clean_age_group("014") == "0-14")
stopifnot(clean_age_group("024") == "0-24")
stopifnot(clean_age_group("64") == "64+")
stopifnot(clean_age_group("4554") == "45-54")
Use the glue package
Attaching package: 'glue'
The following object is masked from 'package:dplyr':
collapse
clean_age_group <- function(age_group_string) {
if (age_group_string == "u") {
return("Unknown")
} else if (str_starts(age_group_string, "0")) {
p1 = str_sub(age_group_string, start = 1, end = 1)
p2 = str_sub(age_group_string, start = 2, end = -1)
#age_cat = paste0(p1, "-", p2)
age_cat = glue("{p1}-{p2}")
return(age_cat)
} else if (age_group_string == "65") {
return("65+")
} else if (nchar(age_group_string) == 4) {
age_cat = paste0(str_sub(age_group_string, start = 1, end = 2), "-", str_sub(age_group_string, start = 3, end = -1))
return(age_cat)
}
}
stopifnot(clean_age_group("014") == "0-14")
stopifnot(clean_age_group("024") == "0-24")
stopifnot(clean_age_group("64") == "64+")
stopifnot(clean_age_group("4554") == "45-54")
Apply functions to data (purrr)
# A tibble: 3,216 × 5
country year sex age_group value
<chr> <dbl> <chr> <chr> <dbl>
1 AD 2000 m 014 0
2 AD 2000 m 1524 0
3 AD 2000 m 2534 1
4 AD 2000 m 3544 0
5 AD 2000 m 4554 0
6 AD 2000 m 5564 0
7 AD 2000 m 65 0
8 AD 2000 m u NA
9 AD 2000 f 014 NA
10 AD 2000 f 1524 NA
# … with 3,206 more rows
tb_tidy %>%
clean_age_group(age_group)
Error in clean_age_group(., age_group): unused argument (age_group)
tb_tidy %>%
mutate(age_cat = clean_age_group(age_group))
Warning in if (age_group_string == "u") {: the condition has length > 1 and only
the first element will be used
Warning in if (str_starts(age_group_string, "0")) {: the condition has length >
1 and only the first element will be used
# A tibble: 3,216 × 6
country year sex age_group value age_cat
<chr> <dbl> <chr> <chr> <dbl> <glue>
1 AD 2000 m 014 0 0-14
2 AD 2000 m 1524 0 1-524
3 AD 2000 m 2534 1 2-534
4 AD 2000 m 3544 0 3-544
5 AD 2000 m 4554 0 4-554
6 AD 2000 m 5564 0 5-564
7 AD 2000 m 65 0 6-5
8 AD 2000 m u NA u-
9 AD 2000 f 014 NA 0-14
10 AD 2000 f 1524 NA 1-524
# … with 3,206 more rows
map_chr(tb_tidy$age_group, clean_age_group)
[1] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[8] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[15] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[22] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[29] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[36] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[43] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[50] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[57] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[64] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[71] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[78] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[85] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[92] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[99] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[106] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[113] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[120] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[127] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[134] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[141] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[148] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[155] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[162] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[169] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[176] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[183] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[190] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[197] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[204] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[211] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[218] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[225] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[232] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[239] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[246] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[253] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[260] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[267] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[274] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[281] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[288] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[295] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[302] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[309] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[316] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[323] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[330] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[337] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[344] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[351] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[358] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[365] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[372] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[379] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[386] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[393] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[400] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[407] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[414] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[421] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[428] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[435] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[442] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[449] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[456] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[463] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[470] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[477] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[484] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[491] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[498] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[505] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[512] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[519] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[526] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[533] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[540] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[547] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[554] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[561] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[568] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[575] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[582] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[589] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[596] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[603] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[610] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[617] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[624] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[631] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[638] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[645] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[652] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[659] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[666] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[673] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[680] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[687] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[694] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[701] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[708] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[715] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[722] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[729] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[736] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[743] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[750] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[757] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[764] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[771] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[778] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[785] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[792] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[799] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[806] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[813] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[820] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[827] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[834] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[841] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[848] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[855] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[862] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[869] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[876] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[883] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[890] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[897] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[904] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[911] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[918] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[925] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[932] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[939] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[946] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[953] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[960] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[967] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[974] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[981] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[988] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[995] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1002] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1009] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1016] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1023] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1030] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1037] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1044] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1051] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1058] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1065] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1072] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1079] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1086] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1093] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1100] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1107] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1114] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1121] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1128] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1135] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1142] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1149] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1156] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1163] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1170] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1177] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1184] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1191] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1198] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1205] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1212] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1219] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1226] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1233] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1240] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1247] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1254] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1261] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1268] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1275] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1282] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1289] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1296] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1303] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1310] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1317] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1324] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1331] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1338] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1345] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1352] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1359] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1366] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1373] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1380] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1387] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1394] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1401] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1408] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1415] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1422] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1429] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1436] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1443] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1450] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1457] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1464] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1471] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1478] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1485] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1492] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1499] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1506] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1513] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1520] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1527] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1534] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1541] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1548] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1555] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1562] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1569] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1576] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1583] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1590] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1597] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1604] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1611] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1618] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1625] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1632] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1639] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1646] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1653] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1660] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1667] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1674] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1681] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1688] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1695] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1702] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1709] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1716] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1723] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1730] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1737] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1744] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1751] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1758] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1765] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1772] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1779] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1786] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1793] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1800] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1807] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1814] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1821] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1828] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1835] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1842] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1849] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1856] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1863] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1870] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1877] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1884] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1891] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1898] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1905] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1912] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1919] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1926] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1933] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1940] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1947] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1954] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1961] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1968] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1975] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1982] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1989] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1996] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2003] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2010] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2017] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2024] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2031] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2038] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2045] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2052] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2059] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2066] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2073] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2080] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2087] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2094] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2101] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2108] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2115] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2122] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2129] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2136] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2143] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2150] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2157] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2164] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2171] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2178] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2185] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2192] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2199] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2206] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2213] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2220] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2227] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2234] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2241] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2248] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2255] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2262] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2269] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2276] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2283] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2290] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2297] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2304] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2311] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2318] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2325] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2332] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2339] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2346] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2353] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2360] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2367] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2374] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2381] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2388] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2395] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2402] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2409] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2416] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2423] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2430] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2437] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2444] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2451] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2458] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2465] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2472] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2479] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2486] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2493] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2500] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2507] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2514] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2521] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2528] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2535] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2542] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2549] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2556] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2563] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2570] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2577] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2584] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2591] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2598] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2605] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2612] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2619] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2626] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2633] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2640] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2647] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2654] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2661] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2668] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2675] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2682] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2689] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2696] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2703] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2710] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2717] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2724] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2731] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2738] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2745] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2752] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2759] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2766] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2773] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2780] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2787] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2794] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2801] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2808] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2815] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2822] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2829] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2836] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2843] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2850] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2857] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2864] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2871] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2878] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2885] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2892] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2899] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2906] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2913] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2920] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2927] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2934] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2941] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2948] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2955] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2962] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2969] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2976] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2983] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2990] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2997] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[3004] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[3011] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[3018] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[3025] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[3032] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[3039] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[3046] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[3053] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[3060] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[3067] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[3074] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[3081] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[3088] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[3095] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[3102] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[3109] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[3116] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[3123] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[3130] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[3137] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[3144] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[3151] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[3158] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[3165] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[3172] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[3179] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[3186] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[3193] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[3200] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[3207] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[3214] "55-64" "65+" "Unknown"
tb_tidy %>%
pull(age_group) %>%
map_chr(clean_age_group)
[1] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[8] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[15] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[22] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[29] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[36] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[43] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[50] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[57] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[64] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[71] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[78] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[85] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[92] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[99] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[106] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[113] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[120] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[127] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[134] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[141] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[148] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[155] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[162] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[169] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[176] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[183] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[190] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[197] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[204] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[211] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[218] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[225] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[232] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[239] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[246] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[253] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[260] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[267] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[274] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[281] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[288] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[295] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[302] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[309] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[316] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[323] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[330] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[337] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[344] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[351] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[358] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[365] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[372] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[379] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[386] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[393] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[400] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[407] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[414] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[421] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[428] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[435] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[442] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[449] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[456] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[463] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[470] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[477] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[484] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[491] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[498] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[505] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[512] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[519] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[526] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[533] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[540] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[547] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[554] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[561] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[568] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[575] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[582] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[589] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[596] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[603] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[610] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[617] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[624] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[631] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[638] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[645] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[652] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[659] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[666] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[673] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[680] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[687] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[694] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[701] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[708] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[715] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[722] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[729] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[736] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[743] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[750] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[757] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[764] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[771] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[778] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[785] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[792] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[799] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[806] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[813] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[820] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[827] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[834] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[841] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[848] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[855] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[862] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[869] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[876] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[883] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[890] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[897] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[904] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[911] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[918] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[925] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[932] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[939] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[946] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[953] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[960] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[967] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[974] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[981] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[988] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[995] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1002] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1009] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1016] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1023] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1030] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1037] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1044] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1051] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1058] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1065] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1072] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1079] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1086] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1093] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1100] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1107] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1114] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1121] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1128] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1135] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1142] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1149] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1156] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1163] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1170] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1177] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1184] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1191] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1198] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1205] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1212] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1219] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1226] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1233] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1240] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1247] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1254] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1261] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1268] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1275] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1282] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1289] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1296] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1303] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1310] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1317] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1324] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1331] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1338] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1345] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1352] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1359] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1366] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1373] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1380] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1387] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1394] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1401] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1408] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1415] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1422] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1429] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1436] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1443] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1450] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1457] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1464] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1471] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1478] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1485] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1492] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1499] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1506] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1513] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1520] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1527] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1534] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1541] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1548] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1555] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1562] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1569] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1576] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1583] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1590] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1597] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1604] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1611] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1618] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1625] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1632] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1639] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1646] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1653] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1660] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1667] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1674] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1681] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1688] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1695] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1702] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1709] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1716] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1723] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1730] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1737] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1744] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1751] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1758] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1765] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1772] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1779] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1786] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1793] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1800] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1807] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1814] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1821] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1828] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1835] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1842] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1849] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1856] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1863] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1870] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1877] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1884] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1891] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1898] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1905] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1912] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1919] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1926] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1933] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1940] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[1947] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[1954] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[1961] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[1968] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[1975] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[1982] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[1989] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[1996] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2003] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2010] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2017] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2024] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2031] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2038] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2045] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2052] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2059] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2066] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2073] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2080] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2087] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2094] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2101] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2108] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2115] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2122] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2129] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2136] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2143] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2150] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2157] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2164] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2171] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2178] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2185] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2192] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2199] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2206] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2213] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2220] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2227] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2234] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2241] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2248] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2255] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2262] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2269] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2276] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2283] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2290] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2297] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2304] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2311] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2318] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2325] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2332] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2339] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2346] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2353] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2360] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2367] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2374] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2381] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2388] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2395] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2402] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2409] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2416] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2423] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2430] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2437] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2444] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2451] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2458] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2465] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2472] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2479] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2486] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2493] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2500] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2507] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2514] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2521] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2528] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2535] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2542] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2549] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2556] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2563] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2570] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2577] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2584] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2591] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2598] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2605] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2612] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2619] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2626] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2633] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2640] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2647] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2654] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2661] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2668] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2675] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2682] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2689] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2696] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2703] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2710] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2717] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2724] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2731] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2738] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2745] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2752] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2759] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2766] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2773] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2780] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2787] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2794] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2801] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2808] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2815] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2822] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2829] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2836] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2843] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2850] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2857] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2864] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2871] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2878] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2885] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2892] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2899] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2906] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2913] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2920] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2927] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2934] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2941] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[2948] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[2955] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[2962] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[2969] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[2976] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[2983] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[2990] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[2997] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[3004] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[3011] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[3018] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[3025] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[3032] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[3039] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[3046] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[3053] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[3060] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[3067] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[3074] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[3081] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[3088] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[3095] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[3102] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[3109] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[3116] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[3123] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[3130] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[3137] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[3144] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[3151] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[3158] "55-64" "65+" "Unknown" "0-14" "15-24" "25-34" "35-44"
[3165] "45-54" "55-64" "65+" "Unknown" "0-14" "15-24" "25-34"
[3172] "35-44" "45-54" "55-64" "65+" "Unknown" "0-14" "15-24"
[3179] "25-34" "35-44" "45-54" "55-64" "65+" "Unknown" "0-14"
[3186] "15-24" "25-34" "35-44" "45-54" "55-64" "65+" "Unknown"
[3193] "0-14" "15-24" "25-34" "35-44" "45-54" "55-64" "65+"
[3200] "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54" "55-64"
[3207] "65+" "Unknown" "0-14" "15-24" "25-34" "35-44" "45-54"
[3214] "55-64" "65+" "Unknown"
tb_tidy <- tb_tidy %>%
mutate(age_cat = map_chr(age_group, clean_age_group))
tb_tidy
# A tibble: 3,216 × 6
country year sex age_group value age_cat
<chr> <dbl> <chr> <chr> <dbl> <chr>
1 AD 2000 m 014 0 0-14
2 AD 2000 m 1524 0 15-24
3 AD 2000 m 2534 1 25-34
4 AD 2000 m 3544 0 35-44
5 AD 2000 m 4554 0 45-54
6 AD 2000 m 5564 0 55-64
7 AD 2000 m 65 0 65+
8 AD 2000 m u NA Unknown
9 AD 2000 f 014 NA 0-14
10 AD 2000 f 1524 NA 15-24
# … with 3,206 more rows
Use processed columns
year_sex_age_count <-tb_tidy %>%
group_by(year, sex, age_cat) %>%
summarize(sum = sum(value, na.rm = TRUE)) %>%
ungroup()
`summarise()` has grouped output by 'year', 'sex'. You can override using the `.groups` argument.
# A tibble: 16 × 4
year sex age_cat sum
<dbl> <chr> <chr> <dbl>
1 2000 f 0-14 14748
2 2000 f 15-24 94643
3 2000 f 25-34 110306
4 2000 f 35-44 74707
5 2000 f 45-54 49823
6 2000 f 55-64 33700
7 2000 f 65+ 33823
8 2000 f Unknown 0
9 2000 m 0-14 12387
10 2000 m 15-24 115246
11 2000 m 25-34 172899
12 2000 m 35-44 156268
13 2000 m 45-54 121278
14 2000 m 55-64 82840
15 2000 m 65+ 75151
16 2000 m Unknown 0
ggplot(year_sex_age_count, aes(x = age_cat, y = sum, fill = sex)) +
geom_bar(stat="identity", position = "dodge")