is_connected: Returns TRUE if the neighboring locations are connected to...

View source: R/zones.R

is_connectedR Documentation

Returns TRUE if the neighboring locations are connected to the given location, FALSE if not.

Description

Returns TRUE if the neighboring locations are connected to the given location, FALSE if not.

Usage

is_connected(neighbor_locations, location, adjacency_matrix)

Arguments

neighbor_locations

A set of neighboring locations to the given location; these neighbors do not include the given location itself.

location

A location, preferably given as an integer.

adjacency_matrix

A boolean matrix, with element (i,j) set to TRUE if location j is adjacent to location i.

Value

Boolean: is the neighbors connected to the given location?


scanstatistics documentation built on Feb. 16, 2023, 10:32 p.m.