Section 1. Chapter 4
single
Challenge: Factors
Swipe to show menu
Task
Swipe to start coding
Practice converting character vectors to factors, reordering their levels, and summarizing the frequency of each category. This exercise reinforces your understanding of categorical data handling in R.
- Convert
char_vecto a factor. - Reorder the factor levels according to
new_order. - Summarize the frequency of each category and return the summary.
Solution
Everything was clear?
Thanks for your feedback!
Section 1. Chapter 4
single
Ask AI
Ask AI
Ask anything or try one of the suggested questions to begin our chat