ons_pop_weight_dbs: Get neighbourhood population-weighted travel distances and...

View source: R/population_weighting.R

ons_pop_weight_dbsR Documentation

Get neighbourhood population-weighted travel distances and times from DBs to facilities

Description

This function calculates neighbourhood-level population-weighted average travel times and distances from each dissemination block (DB) to the n-nearest facilities. Each DB is linked to the single neighbourhood it overlaps the most

It works well with the function valhallr::od_table() from the valhallr package.

Usage

ons_pop_weight_dbs(od_table, n_closest = 5, verbose = TRUE)

Arguments

od_table

A tidy origin-destination table with (at least) columns DBUID, distance, and time. Output from valhallr::od_table() should be accepted seamlessly.

n_closest

The number of closest facilities to consider. Default is 5.

verbose

Boolean. Would you like lots of updates in the console?

Value

A 111-row tibble with population-weighted travel distances and times for each ONS neighbourhood.


Ottawa-Neighbourhood-Study/onsr documentation built on June 19, 2022, 11:46 a.m.