samplePoints | R Documentation |
Sample points along the coastline at specified intervals.
samplePoints(
Coastline = NA,
ShorelinePointDist = 200,
BufferDist = 300,
RadLineDist = 3
)
Coastline |
Coastline LINESTRING of class sf and data.frame. |
ShorelinePointDist |
Numeric. Spacing between cross-shore profile lines (meters). Note that it is recommended to keep this number as large as possible for your area of interest to speed up processing time. |
BufferDist |
Numeric. Buffer search distance (meters) used to identify the perpendicular angle of each cross-shore profile line from the coastline. |
RadLineDist |
Numeric. Radial line distance (kilometers) of the cross-shore profiles. This value determines how for offshore (and onshore) the cross-shore profiles should extend (recommended values are 1 - 3 km). |
A list object of shoreline points and cross-shore profile lines along the coastline.
## Not run:
data(Coastline)
shoreline_points <- samplePoints(
Coastline = Coastline,
ShorelinePointDist = 150, # where to sample points on shoreline
BufferDist = 300.0, # Buffer distance in meters for vertical line
RadLineDist = 3.0 # Line dist in km
)
# Coastline
plot(sf::st_geometry(Coastline))
# Shoreline points
plot(sf::st_geometry(shoreline_points[[1]]), add=TRUE)
# Cross-shore profiles
plot(sf::st_geometry(shoreline_points[[2]]), add=TRUE)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.