Deals Of The Week - hours only!Up to 80% off on all courses and bundles.-Close
Errors
Summary

Instruction

Great! All missing values in the data frame are now encoded as NAs. It seems that our data frame is ready for the next step. NAs are difficult to work with. A common solution, especially if there are few missing values in the data set, is to remove rows with missing values. If we want to remove rows with missing values, we have two options. First, we can use the complete.cases() function, which returns a TRUE/FALSE vector based on the row numbers. If there is at least one NA in a row, the function will return FALSE for that row. Let's check this out.

complete.cases(census2017)

Exercise

Use the complete.cases() function on the census2018 data frame.