binary_distance_matrix: (Internal) Create a binary distance matrix

View source: R/utils.R

binary_distance_matrixR Documentation

(Internal) Create a binary distance matrix

Description

This is a wrapper function that returns a logical matrix, of 1 if distance between element i, j is less than or equal to the distance_cutoff, and 0 otherwise.

Usage

binary_distance_matrix(facility, user, distance_cutoff, d_proposed_user = NULL)

Arguments

facility

data.frame of facilities

user

data.frame of users

distance_cutoff

integer of distance to use for cutoff

d_proposed_user

Option distance matrix between proposed facilities and users (see Examples).

Value

a logical matrix, of 1 if distance between element i, j is less than or equal to the distance_cutoff, and 0 otherwise.


njtierney/maxcovr documentation built on Nov. 27, 2024, 7:51 a.m.