Complete a data.table with missing combinations of data
Turns implicit missing values into explicit missing values.
complete.(.df, ..., fill = list())
.df |
A data.frame or data.table |
... |
Columns to expand |
fill |
A named list of values to fill NAs with. |
test_df <- data.table(x = 1:2, y = 1:2, z = 3:4) test_df %>% complete.(x, y) test_df %>% complete.(x, y, fill = list(z = 10))
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.