Skip to content

Commit 913edae

Browse files
committed
update docs of dist in st_buffer
1 parent e8cce26 commit 913edae

File tree

2 files changed

+14
-6
lines changed

2 files changed

+14
-6
lines changed

R/geom-transformers.R

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,13 @@
66
#' Geometric unary operations on simple feature geometries. These are all generics, with methods for \code{sfg}, \code{sfc} and \code{sf} objects, returning an object of the same class. All operations work on a per-feature basis, ignoring all other features.
77
#' @name geos_unary
88
#' @param x object of class \code{sfg}, \code{sfc} or \code{sf}
9-
#' @param dist numeric; buffer distance for all, or for each of the elements in \code{x}; in case
10-
#' \code{dist} is a \code{units} object, it should be convertible to \code{arc_degree} if
11-
#' \code{x} has geographic coordinates, and to \code{st_crs(x)$units} otherwise
9+
#' @param dist numeric or object of class `units`; buffer distance for all, or for each of the elements in \code{x}.
10+
#' In case \code{x} has geodetic coordinates (lon/lat) and `sf_use_s2()` is `TRUE`, a numeric
11+
#' `dist` is taken as distance in meters and a `units` object in `dist` is converted to meters.
12+
#' In case \code{x} has geodetic coordinates (lon/lat) and `sf_use_s2()` is `FALSE`, a numeric
13+
#' `dist` is taken as degrees, and a `units` object in `dist` is converted to `arc_degree` (and warnings are issued).
14+
#' In case \code{x} does not have geodetic coordinates (projected) then
15+
#' numeric `dist` is assumed to have the units of the coordinates, and a `units` `dist` is converted to those if `st_crs(x)` is not `NA`.
1216
#' @param nQuadSegs integer; number of segments per quadrant (fourth of a circle), for all or per-feature; see details
1317
#' @param endCapStyle character; style of line ends, one of 'ROUND', 'FLAT', 'SQUARE'; see details
1418
#' @param joinStyle character; style of line joins, one of 'ROUND', 'MITRE', 'BEVEL'; see details

man/geos_unary.Rd

Lines changed: 7 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)