wkt: Convert to WKT

Description Usage Arguments Details Examples

View source: R/wkt.R

Description

Convert to Well-Known-Text geometry string format.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
wkt(x, ...)

## S3 method for class 'POINT'
wkt(x, ...)

## S3 method for class 'MULTIPOINT'
wkt(x, ...)

## S3 method for class 'LINESTRING'
wkt(x, ...)

## S3 method for class 'MULTILINESTRING'
wkt(x, ...)

## S3 method for class 'POLYGON'
wkt(x, ...)

## S3 method for class 'MULTIPOLYGON'
wkt(x, ...)

## S3 method for class 'sfc'
wkt(x, ...)

## S3 method for class 'sf'
wkt(x, ...)

Arguments

x

object to format as WKT

...

ignored

Details

Methods exist for the simple features types.

Note, this is not the 'WKT' specification for a coordinate reference sytem (map projection), it's a geometry encoding for points, lines, and polygons.

Examples

1
2
3
wkt(sfobj)
wkt(sfobj$geom)
wkt(sfobj$geom[[2]])

mdsumner/howzat documentation built on Nov. 5, 2019, 2:43 p.m.