Closed
Description
Below is some simplified code to plot a world map using ggplot2. This code was working fine for me until April, at which point I started getting Error: not implemented
. Line by line testing links this outcome to the coord_proj()
line. There was some discussion of this on stackoverflow, but no definitive solution was found. Reproducible example and error messages below.
world <- ggplot2::map_data("world")
world <- world[world$region != "Antarctica",]
gg <- ggplot()
gg <- gg + geom_cartogram(data=world, map=world,
aes(x=long, y=lat, map_id=region))
gg <- gg + coord_proj("+proj=wintri")
gg
Error messages:
Error: Not implemented
Run `rlang::last_error()` to see where the error occurred.
> rlang::last_error()
<error/rlang_error>
Not implemented
Backtrace:
1. (function (x, ...) ...
2. ggplot2:::print.ggplot(x)
4. ggplot2:::ggplot_gtable.ggplot_built(data)
5. base::Map(...)
6. base::mapply(FUN = f, ..., SIMPLIFY = FALSE)
8. l$draw_geom(d, layout)
9. ggplot2:::f(..., self = self)
10. self$geom$draw_layer(data, self$geom_params, layout, layout$coord)
11. ggplot2:::f(..., self = self)
12. base::lapply(...)
13. ggplot2:::FUN(X[[i]], ...)
16. ggalt:::f(...)
17. ggplot2::coord_munch(coord, map, panel_scales)
18. coord$backtransform_range(range)
19. ggplot2:::f(..., self = self)
Run `rlang::last_trace()` to see the full context.
Metadata
Metadata
Assignees
Labels
No labels