Seção 1. Capítulo 8
single
Challenge: Transforming and Recoding Variables
Deslize para mostrar o menu
Tarefa
Deslize para começar a programar
Practice transforming and recoding variables in a simulated dataset using mutate() and case_when().
- Use
mutate()to create a new variable,score_scaled, which is thescoredivided by 100. - Create a new variable,
group_label, usingcase_when()to recode thegroupvariable: "A" becomes "Control", "B" becomes "Treatment", and any other value becomes "Unknown". - Return the resulting data frame with the new variables.
Solução
Tudo estava claro?
Obrigado pelo seu feedback!
Seção 1. Capítulo 8
single
Pergunte à IA
Pergunte à IA
Pergunte o que quiser ou experimente uma das perguntas sugeridas para iniciar nosso bate-papo