Expand and relevel a shadow column with a new suffix
Internal function to handle appropriate expansion and releveling of shadow variables.
shadow_expand_relevel(.var, suffix)
.var |
a variable in a data.frame |
suffix |
a character suffix to add to NA_, e. |
a factor with expanded levels
df <- tibble::tribble( ~wind, ~temp, -99, 45, 68, NA, 72, 25 ) dfs <- bind_shadow(df) test_shade <- dfs$wind_NA # shadow_expand_relevel(test_shade, "weee") # dfs %>% # mutate(temp_NA = shadow_expand_relevel(temp_NA, "weee")) # test that this breaks # shadow_expand_relevel(airquality, "weee")
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.