Description Usage Arguments Value Examples
Removes NA rows. If columns is not 'NULL', then will only remove rows in which all columns given have 'NA'. If columns is 'NULL', then will remove rows that are 'NA' across all columns.
1 | remove_na_rows(data, columns = NULL)
|
data |
Data frame with metadata |
columns |
The columns to compare for 'NA' values. |
The data without rows that are 'NA' across the given columns.
1 2 3 4 5 6 7 8 9 10 | ## Not run:
dat <- data.frame(
foo = c("bar0", NA, NA, "bar3"),
bar = c(NA, "foo1", NA, "foo3")
)
dat1 <- remove_na_rows(dat)
dat2 <- remove_na_rows(dat, "foo")
dat3 <- remove_na_rows(dat, c("foo", "bar"))
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.