read.coastline.shapefile | R Documentation |
Read coastline data stored in the shapefile format (see reference 1).
read.coastline.shapefile(
file,
lonlim = c(-180, 180),
latlim = c(-90, 90),
encoding = NA,
monitor = FALSE,
debug = getOption("oceDebug"),
processingLog
)
file |
name of file containing coastline data (a file ending in |
lonlim , latlim |
numerical vectors specifying the west and east edges (and south and north edges) of a focus window. Coastline polygons that do not intersect the defined box are skipped, which can be useful in narrowing high-resolution world-scale data to a local application. |
encoding |
ignored. |
monitor |
Logical indicating whether to print an indication of progress through the file. |
debug |
set to TRUE to print information about the header, etc. |
processingLog |
if provided, the action item to be stored in the log. (Typically only provided for internal calls; the default that it provides is better for normal calls by a user.) |
x a coastline object.
The following demonstrates that this code is getting close to working with depth contours. This should be handled more internally, and a new object for depth contours should be constructed, of which coastlines could be a subset.
Dan Kelley
The “shapefile” format is described in
ESRI Shapefile Technical Description, March 1998, available at
https://www.esri.com/content/dam/esrisites/sitecore-archive/Files/Pdfs/library/whitepapers/pdfs/shapefile.pdf
(last checked 2021-03-24).
The NaturalEarth website https://www.naturalearthdata.com/downloads/
provides coastline datasets in three resolutions, along with similar files
lakes and rivers, for borders, etc. It is highly recommended.
Other things related to coastline data:
[[,coastline-method
,
[[<-,coastline-method
,
as.coastline()
,
coastline-class
,
coastlineBest()
,
coastlineCut()
,
coastlineWorld
,
download.coastline()
,
plot,coastline-method
,
read.coastline.openstreetmap()
,
subset,coastline-method
,
summary,coastline-method
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.