Description Usage Arguments Value See Also Examples
Create a polygon
1 | lawn_polygon(coordinates, properties = NULL)
|
coordinates |
A list of LinearRings, or in json. |
properties |
A list of properties. |
A data-Polygon feature.
Other data functions:
lawn_featurecollection()
,
lawn_feature()
,
lawn_filter()
,
lawn_geometrycollection()
,
lawn_linestring()
,
lawn_multilinestring()
,
lawn_multipoint()
,
lawn_multipolygon()
,
lawn_point()
,
lawn_random()
,
lawn_remove()
,
lawn_sample()
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | rings <- list(list(
c(-2.275543, 53.464547),
c(-2.275543, 53.489271),
c(-2.215118, 53.489271),
c(-2.215118, 53.464547),
c(-2.275543, 53.464547)
))
lawn_polygon(rings)
lawn_polygon(rings, properties = list(name = 'poly1', population = 400))
# Make a FeatureCollection
lawn_featurecollection(lawn_polygon(rings))
## Not run:
lawn_featurecollection(lawn_polygon(rings)) %>% view
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.