-
Notifications
You must be signed in to change notification settings - Fork 11
Open
Description
Documentation claims:
An object of class sf is a data.frame with a geometry list-column. Set the layer prop that fetches the geometry to the geometry list-column of your sf object:
> # Example: PolygonLayer
>
> props <- list(
> getPolygon = ~geometry
> # ...
> )
This R script shows this is not the case.
library(sf)
library(deckgl)
nc <- st_read(system.file("shape/nc.shp", package="sf"))
deck <- deckgl() %>%
add_polygon_layer(
data = nc,
properties = list(getPolygon = ~geometry)
) %>%
add_basemap()
if (interactive()) deck
When opened and inspected in the browser, there is the following error "deck: error during initialization of PolygonLayer({id: 'polygon-layer'}) Error: invalid polygon"
Metadata
Metadata
Assignees
Labels
No labels