knitr::opts_chunk$set( collapse = TRUE, comment = "#>" )
library(tissot) library(rnaturalearth) library(sf) library(rgeos)
w <- ne_countries(scale = "medium", returnclass = "sf") w_geom = st_geometry(w) unprojected = tissot(5) # plot(w_geom,axes = TRUE, graticule = TRUE) plot(unprojected, col = "red")
x = unprojected st_crs(x) <- st_crs(3857) plot(w_geom,axes = TRUE, graticule = TRUE) plot(x,col = "red")
# eckert-IV eckert <- st_transform(x,"+proj=eck4 +ellps=WGS84 +datum=WGS84 +units=m") w_eck <- st_transform(w_geom,st_crs("+proj=eck4 +ellps=WGS84 +datum=WGS84 +units=m")) plot(w_eck,axes = TRUE, graticule = TRUE) plot(eckert,col = "red")
equal_earth = st_transform(x,8857) w_ea <- st_transform(w_geom,8857) plot(w_ea,axes = TRUE, graticule = TRUE) plot(equal_earth,col = "red")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.