-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Hi,
Thanks for developing this package. It's amazing! I'm new to this, so forgive me for probably a simple question. I've been looking for more examples, and haven't come across what I need.
I'm trying to add two numeric data fields from my vector tile, and use the results in the color scaling function for the map. The code below works with just one data field (DM_W), but not when I try to combine two fields (e.g., DM_W + DM_A) as shown. Any suggestions would be appreciated.
rdeck() |>
add_mvt_layer(
data = tile_json("https://{my server's IP}/services/simple_polygons"),
get_fill_color = scale_color_linear(
col = DM_W + DM_A
),
pickable = TRUE,
tooltip = c(GEOID10, DM_W, DM_A),
)
I get an error...
Error in `add_mvt_layer()`:
! Failed to create layer
Caused by error in `rlang::ensym()`:
! Can't convert to a symbol.
Run `rlang::last_trace()` to see where the error occurred.
From the ensym() error, I think it's expecting just a column name rather than an expression, but my R skills aren't good enough to come up with a work around.
Metadata
Metadata
Assignees
Labels
No labels