0

I've had trouble increasing the radius of the circle on a map. I've tried the scale_size_continuous with maximum size up to 1000, but the circle size remained the same after all.

My code is in the following:

states <- map_data("state")

gg1 <- ggplot(data=states) +
  geom_polygon(data=states, aes(x=long,y=lat,group=group), 
               fill = "orange", color = "white") + 
  coord_fixed(ratio = 1.3)+
  geom_circle(data = origCity, aes(x0 = Long, y0 = Lat, r = Percent), 
              fill = "black", color = "black", alpha = 0.5, show.legend = FALSE) +
  scale_size_continuous(range = c(20, 5))+
  theme(panel.grid.major = element_blank(),
        panel.grid.minor = element_blank(), 
        panel.background = element_blank())+
  theme(axis.ticks.x = element_blank(),
        axis.title.x = element_blank(),
        axis.text.x = element_blank())+
  theme(axis.ticks.y = element_blank(),
        axis.title.y = element_blank(),
        axis.text.y = element_blank())

print(gg1)

Any suggestions are greatly appreciated!

Z.Lin
  • 28,055
  • 6
  • 54
  • 94
zhshzh44
  • 3
  • 2
  • 3
    Please [see here](https://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example) on posting an R question that is easy for folks to answer. That includes a representative sample of your data and relevant information about your code (such as where `geom_circle` comes from). – camille Jun 27 '18 at 17:09
  • Where does `origCity` come from? Can you post it using `dput`? – Dan Jun 27 '18 at 17:29
  • Assuming you are using `geom_circle` from the `ggforce` package, the circle's size is controlled by its radius through `r = Percent`, not `scale_size_XXX`. Try increasing the radius with `r = Percent * 10` or some other multiplier? – Z.Lin Jun 28 '18 at 02:24

0 Answers0