aw_interpolater performs pipeline of interpolation specific calculations with aw_intersect, aw_total, aw_weight, aw_calculate, and aw_aggregate. The interpolated total is then verified against the total calculated from the source data using aw_verify.

aw_interpolater(source, sid, value, target, tid, type, weight)

Arguments

source

A sf object with data to be interpolated

sid

A unique identification number within source

value

A column within source to be interpolated

target

A sf object that data should be interpolated to

tid

A unique identification number within target

type

One of either "extensive" (if the data are spatially extensive e.g. population counts), "intensive" (if the data are spatially intensive e.g. population density), or "mixed" (if the data include both extensive and intensive values). If "extensive", the sum is returned for the interpolated value. If "intensive", the mean is returned for the interpolated value. If "mixed", vectors named "extensive" and "intensive" containing the relevant variable names should be specified in the dots.

weight

For "extensive" interpolations; should be either "total" or "sum".

Value

A sf object or tibble with value interpolated into the target data.