Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

polys() doesn't seem to work with plet() (like points() and lines() do) #1543

Closed
AMBarbosa opened this issue Jun 13, 2024 · 1 comment
Closed

Comments

@AMBarbosa
Copy link
Contributor

v <- vect(system.file("ex/lux.shp", package="terra"))
p <- spatSample(as.polygons(v, ext=T), 30)

points() and lines() work as expected:

plet(v, border = "blue", lwd = 4) |>
  lines(v, lwd = 0.5, col="white") |>
  points(p)

With polys(), however:

plet(p) |> polys(v)

Error: unable to find an inherited method for function ‘polys’ for signature ‘x = "leaflet"’

Regards!

@rhijmans
Copy link
Member

Implemented now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants