Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

wkb_ranges

Extract ranges information


Description

This is intended to behave the same as range(), returning the minimum and maximum x, y, z, and m coordinate values.

Usage

wkb_ranges(wkb, na.rm = FALSE, finite = FALSE)

wkt_ranges(wkt, na.rm = FALSE, finite = FALSE)

wkb_feature_ranges(wkb, na.rm = FALSE, finite = FALSE)

wkt_feature_ranges(wkt, na.rm = FALSE, finite = FALSE)

Arguments

wkb

A list() of raw() vectors, such as that returned by sf::st_as_binary().

na.rm

Pass TRUE to not consider missing (nan) values

finite

Pass TRUE to only consider finite (non-missing, non-infinite) values.

wkt

A character vector containing well-known text.

Value

A data.frame with columns:

  • xmin, ymin, zmin, and mmin: Minimum coordinate values

  • xmax, ymax, zmax, and mmax: Maximum coordinate values

Examples

wkt_ranges("POINT (30 10)")

wkutils

Utilities for Well-Known Geometry Vectors

v0.1.1
MIT + file LICENSE
Authors
Dewey Dunnington [aut, cre] (<https://orcid.org/0000-0002-9415-4582>)
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.