find_overlap: Find overlap between vessel track points

Description Usage Arguments Value

View source: R/find_overlap.R

Description

Find overlap between vessel track points. Note: this function is highly experimental and still needs to be documented.

Usage

1
2
3
4
5
6
7
8
9
find_overlap(
  df,
  time_range,
  speed_range,
  time_col = "DATE",
  speed_col = "SPE",
  lon_col = "LON",
  lat_col = "LAT"
)

Arguments

df

A data frame consisting of a time series. Each observation is a point in time. The time points must be evenly spaced.

time_range

A time range, in the form of a two-element vector.

speed_range

A vessel speed range, also in the form of a two-element vector.

time_col

A string indicating the name of the column that contains the time values.

speed_col

A string indicating the name of the column that contains the speed values.

lon_col

A string indicating the name of the column that contains the longitude values.

lat_col

A string indicating the name of the column that contains the latitude values.

Value

A tibble whose observations are the closest points, i.e., the first row contains information about the point closest to the first, the second row, about the point closest to the second, and so on. These are the columns:

arg_min_dist

The index of closest point.

min_dist

The distance to the closest point.


ramiromagno/fishy documentation built on Feb. 18, 2022, 9 a.m.