Adding region centers coordinate to a data frame
addCenters(dat, labpt, ID = "region", pref = paste0(ID, "."), sfx = NULL)
dat | data.frame, should have a column with regions' IDs |
---|---|
labpt | data.frame with regions' coordinates |
ID | character, name of the column with region IDs (default = "region") |
pref | tbd |
sfx | tbd |