Get startedGet started for free

From tidy to table to tidy

The gss_party dataset that you created is in a tidy format to facilitate visualization and analysis. In this exercise, you'll untidy the data to create a contingency table to display counts. As a data analyst, it's commonplace to be given data in a contingency table, so you'll also practice tidying it back up.

This exercise is part of the course

Inference for Categorical Data in R

View Course

Hands-on interactive exercise

Have a go at this exercise by completing this sample code.

# Create table of natspac and party
___ <- ___
  # Select columns of interest
  ___
  # Create table
  ___
Edit and Run Code