Created
May 14, 2021 20:09
-
-
Save michaeldorman/d52bed143ced2cf9e258097c65968d2a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(ggplot2) | |
library(sf) | |
# Prepare layer | |
dat = data.frame( | |
name = c("Beer-Sheva Center", "Beer-Sheva University", "Dimona"), | |
lon = c(34.79844, 34.81283, 35.01163), | |
lat = c(31.24329, 31.26028, 31.06862) | |
) | |
dat = st_as_sf(dat, coords = c("lon", "lat"), crs = 4326) | |
# Plot | |
ggplot(data = dat) + | |
geom_sf() + | |
geom_sf_text(aes(label = name)) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment