Hi,
on current mapview@develop, the raster legend is apparently not properly updated when manually specifying breaks. For example:
library(raster)
library(mapview)
f <- system.file("external/test.grd", package="raster")
r <- raster(f)
pal <- grDevices::colorRampPalette(RColorBrewer::brewer.pal(5, "RdYlGn"))
mapview(r, col.regions= pal)
gives:

, but if we manually specify breaks, the map is modified, but the legend is no longer "correct":
brks <- classInt::classIntervals(1:10000,
style = "fixed",
fixedBreaks = seq(0,10000,500),
intervalClosure = "right")
mapview(r, col.regions= pal, at = brks$brks)

I may be wrong, but I think previous mapview behaviour was different, and the legend followed the specified "breaks". Am I wrong?
HTH,
Lorenzo
Hi,
on current mapview@develop, the raster legend is apparently not properly updated when manually specifying breaks. For example:
gives:
, but if we manually specify breaks, the map is modified, but the legend is no longer "correct":
I may be wrong, but I think previous
mapviewbehaviour was different, and the legend followed the specified "breaks". Am I wrong?HTH,
Lorenzo