This function is conditional on the variable having value labels.

extract_vallab(x, variable)

Arguments

x

Data frame or tibble containing the variable

variable

Enter variable name as string