SyntaxFix
Write A Post
Hire A Developer
Questions
Late to the game but you can also use the janitor package. This function will remove columns which are all NA, and can be changed to remove rows that are all NA as well.
janitor
df <- janitor::remove_empty(df, which = "cols")