Skip to contents

Absolute distance of data points from the nearest plate boundary in degree

Usage

distance_from_pb(x, PoR, pb, tangential = FALSE, km = FALSE, ...)

Arguments

x, pb

sf objects of the data points and the plate boundary geometries in the geographical coordinate system

PoR

Pole of Rotation. "data.frame" or object of class "euler.pole" containing the geographical coordinates of the Pole of Rotation

tangential

Logical. Whether the plate boundary is a tangential boundary (TRUE) or an inward and outward boundary (FALSE, the default).

km

Logical. Whether the distance is expressed in kilometers (TRUE) or in degrees (FALSE, the default).

...

optional arguments passed to smoothr::densify()

Value

Numeric vector of the great circle distances

Details

The distance to the plate boundary is the longitudinal or latitudinal difference between the data point and the plate boundary (along the closest latitude or longitude) for inward/outward or tangential plate boundaries, respectively.

References

Wdowinski, S. (1998). A theory of intraplate tectonics. Journal of Geophysical Research: Solid Earth, 103(3), 5037<U+2013>5059. http://dx.doi.org/10.1029/97JB03390

Examples

data("nuvel1")
na_pa <- subset(nuvel1, nuvel1$plate.rot == "na")

data("plates")
plate_boundary <- subset(plates, plates$pair == "na-pa")

data("san_andreas")
res <- distance_from_pb(
  x = san_andreas, PoR = na_pa, pb = plate_boundary, tangential = TRUE
)
head(res)
#> [1] -0.15965337  0.08688785  0.14986772  0.38296977 -0.04424539  0.33684309

res.km <- distance_from_pb(
  x = san_andreas, PoR = na_pa, pb = plate_boundary, tangential = TRUE, km = TRUE
)
range(res.km)
#> [1] -1025.9419   597.3071