Only this week, get the SQL Complete Track of 9 courses in a special prize of $330 $89!
Final quiz


Currently, the levels of marital status are Single, Divorced, Married, Widowed, and Separated. Instead, we want to have only two categories of marital status: single and married. For the sake of this exercise, we consider people who are Separated as single.


Change the factor levels of marital_status to single and married, as appropriate.

Stuck? Here's a hint!


personal_info$marital_status <- fct_collapse(
  single  = c("Single", "Divorced", "Widowed", "Separated"),
  married = c("Married"))