Tidy Data Rule #2: Every Row is an Observation
This lesson is called Tidy Data Rule #2: Every Row is an Observation, part of the R in 3 Months (Spring 2026) course. This lesson is called Tidy Data Rule #2: Every Row is an Observation, part of the R in 3 Months (Spring 2026) course.
Transcript
Click on the transcript to go to that point in the video. Please note that transcripts are auto generated and may contain minor inaccuracies.
Loading transcript...
Your Turn
Run the following code to view the built-in gss_cat data frame.
library(tidyverse)
gss_cat |>
view()
Then, write code to count the number of unique responses in the partyid variable.
You’ll need to use the separate_longer_delim() and count() functions to do this.
Learn More
This lesson from the R for Social Scientists course materials covers separate_longer_delim().
Have any questions? Put them below and we will help you out!
Course Content
144 Lessons
You need to be signed-in to comment on this post. Login.