data("popUK")
uk <- UK(data = popUK, unit = "county", matchWith = "code")
### Adding two varaibles
# \donttest{
uk2 <- UK(data = popUK, unit = "county", matchWith = "code",
add = ~I(population/1000) + I(population/100) )
### Adding to variables and names
uk3 <- UK(data = popUK, unit = "county", matchWith = "code",
add = ~I(population/1000) + I(population/100),
new_var_names = c("ratio1", "ratio2"))
# }
Run the code above in your browser using DataLab