View source: R/s2-transformers.R
s2_project | R Documentation |
Linear referencing
s2_project(x, y, radius = s2_earth_radius_meters())
s2_project_normalized(x, y)
s2_interpolate(x, distance, radius = s2_earth_radius_meters())
s2_interpolate_normalized(x, distance_normalized)
x |
A simple polyline geography vector |
y |
A simple point geography vector. The point will be
snapped to the nearest point on |
radius |
Radius of the earth. Defaults to the average radius of
the earth in meters as defined by |
distance |
A distance along |
distance_normalized |
A |
s2_interpolate()
returns the point on x
, distance
meters
along the line.
s2_interpolate_normalized()
returns the point on x
interpolated
to a fraction along the line.
s2_project()
returns the distance
that point
occurs along x
.
s2_project_normalized()
returns the distance_normalized
along x
where point
occurs.
s2_project_normalized("LINESTRING (0 0, 0 90)", "POINT (0 22.5)")
s2_project("LINESTRING (0 0, 0 90)", "POINT (0 22.5)")
s2_interpolate_normalized("LINESTRING (0 0, 0 90)", 0.25)
s2_interpolate("LINESTRING (0 0, 0 90)", 2501890)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.