highlight.borders: Creates a SpatialPoints object identifying a subset of...

Description Usage Arguments Value Author(s) Examples

View source: R/highlight.borders.R

Description

Creates a SpatialPoints object identifying a subset of borders between neighbouring areas, which allows them to be overlayed on a map. An example is given in the vignette accompanying this package.

Usage

1
highlight.borders(border.locations, spdata)

Arguments

border.locations

A K by K matrix, where K is the number of areas, containing 3 distinct values: NA for non-neighbouring areas; 0 for borders between neighbouring areas to be highlighted on a map; and 1 for borders between neighbouring areas not to be highlighted on a map.

spdata

The SpatialPolygonsDataFrame object used for plotting the data and creating the original neighbourhood matrix W.

Value

A SpatialPoints object from the sp package, which contains the vertices of all the borders to be highlighted on the map. The mapping can be done using the leaflet package, see the vignette accompanying this package for an example.

Author(s)

Duncan Lee

Examples

1
## See the vignette accompanying this package for an example of its use.

duncanplee/CARBayes documentation built on Sept. 9, 2018, 7:37 p.m.