cps_education <- function(education_var) {
if(is.na(education_var)) {
"Missing/Unknown"
} else if(education_var <= 072) {
"Less than high school"
} else if (education_var == 073) {
"High school completion"
} else if (between(education_var, 080, 110)) {
"Some college or associate's degree"
} else if (education_var == 111) {
"Bachelor's degree"
} else if (between(education_var, 120, 125)) {
"Advanced degree"
} else {
"Missing/Unknown"
}
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.