kml_bounds: Find the boundaries of a KML file.

Description Usage Arguments Value See Also Examples

Description

Find the boundaries of a KML file.

Usage

1
kml_bounds(x, ns = "d1", verbose = TRUE)

Arguments

x

A KML source. See kml_read. x can also be a data frame with two numeric variables named longitude and latitude.

ns

The name of the namespace to extract from: defaults to "d1".

verbose

Whether to report invalid coordinates and/or altitudes below sea level; defaults to TRUE. See kml_coords.

Value

A named numeric vector of four elements corresponding to the left, bottom, right and top values of the bounding box; 'left' and 'right' are the minimal and maximal longitudes; 'bottom' and 'top' are the minimal and maximal latitudes.

See Also

kml_coords

Examples

1
2
3
4
# demo data: U.S. Civil War map
# see ?states for details
f <- system.file("extdata", "states.kml.zip", package = "tidykml")
kml_bounds(f)

briatte/tidykml documentation built on May 13, 2019, 7:43 a.m.