Challenge: Grades Summary
Uppgift
Swipe to start coding
You have a factor vector, grades_f, which assigns each numeric grade into one of five categories ('F', 'D', 'C', 'B', 'A'). Your goal is to:
- Use the
summary()function ongrades_fto display the number of occurrences of each grade. - Compute the relative frequency of each grade by dividing the counts from the previous step by the total number of grades. To find the total, call the
length()function ongrades_f.
Lösning
Var allt tydligt?
Tack för dina kommentarer!
Avsnitt 1. Kapitel 26
single
Fråga AI
Fråga AI
Fråga vad du vill eller prova någon av de föreslagna frågorna för att starta vårt samtal
Fantastiskt!
Completion betyg förbättrat till 2.27
Challenge: Grades Summary
Svep för att visa menyn
Uppgift
Swipe to start coding
You have a factor vector, grades_f, which assigns each numeric grade into one of five categories ('F', 'D', 'C', 'B', 'A'). Your goal is to:
- Use the
summary()function ongrades_fto display the number of occurrences of each grade. - Compute the relative frequency of each grade by dividing the counts from the previous step by the total number of grades. To find the total, call the
length()function ongrades_f.
Lösning
Var allt tydligt?
Tack för dina kommentarer!
Avsnitt 1. Kapitel 26
single