Percentile Map Using TMap

I am trying to plot a percentile map but it is taking really long time to load. I am trying to show the percentile map of Covid_Per_10k in ID but right now it is not showing. Here's my code.

percent <- c(0,.01,.1,.5,.9,.99,1)

Jakarta_Covid_Casesa <- Jakarta_Covid_Casesa["Covid_Per_10k"]

Jakarta_Covid_Casesa <- Jakarta_Covid_Casesa %>% 
  dplyr::summarise(quant = quantile(Covid_Per_10k, percent)) %>% 
  cbind(percent) 

tm_shape(Jakarta_Covid_Cases) +
  tm_polygons() + tm_shape(Jakarta_Covid_Cases) +
  tm_fill(Jakarta_Covid_Cases["Covid Cases Per 10,000 Population"],
          title="Covid_Per_10k",
          breaks=Jakarta_Covid_Casesa,
          palette="Blues",
          labels=c("< 1%", "1% - 10%",
                   "10% - 50%", 
                   "50% - 90%",
                   "90% - 99%", 
                   "> 99%"))  +
  tm_borders() +
  tm_layout(title = "Percentile Map", 
            title.position = c("right",
                               "bottom")))

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.