allocate_electorate: Determine which electoral division contains the centroid from...

Description Usage Arguments Value Examples

View source: R/interpolation.R

Description

Using the electoral boundaries at the time of an election and the centroids from the SA1 polygons from a neighbouring Census, allocate each SA1 to the electoral division that contains its centroid.

Usage

1
2
3
4
5
6
allocate_electorate(
  centroids_ls,
  electorates_sf,
  census_year = NA,
  election_year = NA
)

Arguments

centroids_ls

list containing centroids as SpatialPoints and a dataframe with basic data on each polygon (e.g. name)

electorates_sf

shapefile with electoral boundaries

census_year

census year

election_year

election year

Value

data frame detailing which electoral division each Census polygon is allocated to

Examples

1
2
3
4
5
6
## Not run: 
# Mapping each SA1 from the 2011 Census to the 2013 electoral boundaries
mapping_c11_e13 <- allocate_electorate(centroids_ls = centroids_sa1_2011, electorates_sf = sF_13, 
census_year = "2011", election_year = "2013")

## End(Not run)

eechidna documentation built on Feb. 25, 2021, 5:08 p.m.