Tmap in R : How can I set hist legend on maps?

24 Views Asked by At

I'm new to working with geographic data, and I'm trying to add a histogram legend with following code.

density <-
  tm_shape(density)+
  tm_borders(col = "lightgrey") +
  tm_fill( "counts" , 
           style="fixed", 
           breaks =c(0,1,500,1000,1500,2000),
           palette ="Blues",
           legend.hist=TRUE)

I've set the legend.hist to TRUE in tm_fill, but it is still not displaying in the result. My tmap is updated to 3.99.9000. What could the potential problem be?

0

There are 0 best solutions below