Challenge: Create and Use Factors
Tarefa
Swipe to start coding
Create a factor variable from a vector of survey responses and set a custom order for its levels.
- Convert the
survey_responsesvector into a factor. - Use the order: "Dissatisfied", "Neutral", "Satisfied" for the factor levels.
- Assign the factor to a variable named
satisfaction_factor. - The factor should be ordered.
- Display the structure of the factor using the
str()function and assign the result tostructure_info.
Solução
Tudo estava claro?
Obrigado pelo seu feedback!
Seção 3. Capítulo 2
single
Pergunte à IA
Pergunte à IA
Pergunte o que quiser ou experimente uma das perguntas sugeridas para iniciar nosso bate-papo
Incrível!
Completion taxa melhorada para 5.56
Challenge: Create and Use Factors
Deslize para mostrar o menu
Tarefa
Swipe to start coding
Create a factor variable from a vector of survey responses and set a custom order for its levels.
- Convert the
survey_responsesvector into a factor. - Use the order: "Dissatisfied", "Neutral", "Satisfied" for the factor levels.
- Assign the factor to a variable named
satisfaction_factor. - The factor should be ordered.
- Display the structure of the factor using the
str()function and assign the result tostructure_info.
Solução
Tudo estava claro?
Obrigado pelo seu feedback!
Seção 3. Capítulo 2
single