mpa_match: Given a set of MPAs and observations determine which...

Description Usage Arguments Value

View source: R/mpa.R

Description

Given a set of MPAs and observations determine which observations belong to which MPA

Usage

1
mpa_match(mpa = read_mpa("Cuba"), obs = random_points(mpa), ...)

Arguments

mpa

sf object of MPA polygons

obs

sf object of observation points

...

other arguments for st_intersects

Value

a list of match vectors by index. If obs has 1000 points then a 1000 length list of integer vectors is returned where each vector has zero or more integers indicating which mpa polygon each belongs to. For example, the first 3 points below do not intersect any polygons, while the 4th intersects with 3 polygons and the the 5th intersects with just one.


BigelowLab/mpatools documentation built on Jan. 20, 2022, 3:46 p.m.