Why does coord_map produce a weird output?

前端 未结 3 2143
梦毁少年i
梦毁少年i 2021-02-20 02:19

I\'m trying to draw a world map using ggplot. My code is in my gist file. The output is correct when I don\'t use coord_map but very strange when I use

3条回答
  •  你的背包
    2021-02-20 02:58

    Another solution is to use wrld_simpl from maptools instead, but it retains issues with Antarctica.

    require(maptools)
    require(ggmap)
    
    md <- map_data("world2")
    data(wrld_simpl)
    ggplot(wrld_simpl, aes(group = group, x = long, y = lat)) +
      geom_map() +
      coord_map()
    

    Imgur

提交回复
热议问题