Code
library(sf)
library(tmap)
library(dplyr)
library(stringr)
library(ggplot2)Second-largest and second-most populous continent.
library(sf)
library(tmap)
library(dplyr)
library(stringr)
library(ggplot2)focus <- "Africa"
lon0 <- 18
lat0 <- 0
proj <- str_glue("+proj=ortho lon_0={lon0} lat_0={lat0}")
world <- st_read("data/ne_110m_admin_0_map_units.gpkg") %>%
  st_make_valid() %>%
  select(CONTINENT)
world_o <- world %>%
  st_transform(proj) %>%
  st_make_valid() %>%
  filter(!st_is_empty(.)) %>%
  group_by(CONTINENT) %>%
  summarise() 
continent <- world %>%
  filter(CONTINENT == focus)tmapggplot2