This function identifies the population weighted centroids for all areas in your original map.

weightGATmap(area, pop, idvar, popvar, crs = NULL)

Arguments

area

Spatial layer representing areas to be aggregated.

pop

Spatial layer containing underlying population values.

idvar

Variable of unique string values to identify the layer's observations.

popvar

The base population variable.

crs

User-defined non-lat/long projection, entered as a string. For the default, NULL, the function defines the projection.

Examples


if (interactive()) {
cen <- weightGATmap(area = hftown, pop = hfpop, idvar = "ID", popvar = "Pop")
}