banner



How To Draw A Map With R

          library(tidyverse) library(sf) library(here)  options(digits = 3) fix.seed(1234) theme_set(theme_minimal())                  

Unlike raster prototype maps, vector maps require you to obtain spatial information files which contain detailed data necessary to draw all the components of a map (e.g. points, lines, polygons). Once yous successfully import that data into R, ggplot2 works with simple features data frames to easily generate geospatial visualizations using all the core elements and approaches of ggplot().

Import Us country boundaries

First we volition import a spatial data file containing the boundaries of all 50 states in the United States1 using sf::st_read():

          usa <- hither(   "static", "data", "census_bureau",   "cb_2013_us_state_20m", "cb_2013_us_state_20m.shp" ) %>%   st_read()                  
          ## Reading layer `cb_2013_us_state_20m' from data source `/Users/soltoffbc/Projects/Computing for Social Sciences/class-site/static/data/census_bureau/cb_2013_us_state_20m/cb_2013_us_state_20m.shp' using driver `ESRI Shapefile' ## Simple characteristic collection with 52 features and 9 fields ## Geometry blazon: MULTIPOLYGON ## Dimension:     XY ## Bounding box:  xmin: -179 ymin: 17.nine xmax: 180 ymax: 71.iv ## Geodetic CRS:  NAD83                  

Draw the boundaries

ggplot2 contains a geometric object specifically for simple feature objects called geom_sf(). This works reasonably well when you need to draw polygons, like our state boundaries. Support for elementary features in ggplot2 is under active development, so you may not observe adequate support for plotting line or point features. To draw the map, we pass the simple features data frame as the data argument.

          ggplot(data = usa) +   geom_sf()                  

Because simple features information frames are standardized with the geometry cavalcade always containing data on the geographic coordinates of the features, we do not need to specify additional parameters for aes(). Notice a problem with the map above: it wastes a lot of space. This is acquired by the presence of Alaska and Hawaii in the dataset. The Aleutian Islands cross the the 180th meridian, requiring the map to prove the Eastern hemisphere. Likewise, Hawaii is substantially distant from the continental United States.

Plot a subset of a map

One solution is to plot just the lower 48 states. That is, exclude Alaska and Hawaii, as well as DC and Puerto Rico.2 Because simple features data frames contain one row per feature and in this example a feature is defined as a state, we can employ filter() from dplyr to exclude these four states/territories.

          (usa_48 <- usa %>%   filter(!(Proper name %in% c("Alaska", "District of Columbia", "Hawaii", "Puerto Rico"))))                  
          ## Simple feature collection with 48 features and 9 fields ## geometry blazon:  MULTIPOLYGON ## dimension:      XY ## bbox:           xmin: -125 ymin: 24.five xmax: -66.9 ymax: 49.4 ## geographic CRS: NAD83 ## Outset 10 features: ##    STATEFP  STATENS    AFFGEOID GEOID STUSPS        NAME LSAD    ALAND   AWATER ## 1       01 01779775 0400000US01    01     AL     Alabama   00 ane.31e+eleven 4.59e+09 ## 2       05 00068085 0400000US05    05     AR    Arkansas   00 1.35e+11 2.96e+09 ## 3       06 01779778 0400000US06    06     CA  California   00 four.03e+xi ii.05e+10 ## 4       09 01779780 0400000US09    09     CT Connecticut   00 1.25e+10 1.82e+09 ## 5       12 00294478 0400000US12    12     FL     Florida   00 ane.39e+11 3.14e+10 ## 6       13 01705317 0400000US13    13     GA     Georgia   00 1.49e+11 4.95e+09 ## seven       xvi 01779783 0400000US16    16     ID       Idaho   00 ii.14e+11 2.40e+09 ## eight       17 01779784 0400000US17    17     IL    Illinois   00 1.44e+eleven 6.20e+09 ## 9       xviii 00448508 0400000US18    eighteen     IN     Indiana   00 9.28e+10 one.54e+09 ## ten      20 00481813 0400000US20    twenty     KS      Kansas   00 two.12e+xi 1.35e+09 ##                          geometry ## ane  MULTIPOLYGON (((-88.three 30.2,... ## 2  MULTIPOLYGON (((-94.half-dozen 36.5,... ## 3  MULTIPOLYGON (((-119 33.5, ... ## 4  MULTIPOLYGON (((-73.seven 41.one,... ## 5  MULTIPOLYGON (((-eighty.vii 24.9,... ## 6  MULTIPOLYGON (((-85.6 35, -... ## 7  MULTIPOLYGON (((-117 44.4, ... ## 8  MULTIPOLYGON (((-91.5 twoscore.2,... ## ix  MULTIPOLYGON (((-88.1 37.nine,... ## 10 MULTIPOLYGON (((-102 40, -ane...                  
          ggplot(information = usa_48) +   geom_sf()                  

Since the map is a ggplot() object, it tin can hands be modified like any other ggplot() graph. Nosotros could change the color of the map and the borders:

          ggplot(data = usa_48) +   geom_sf(fill = "palegreen", color = "black")                  

albersusa

Rather than excluding them entirely, well-nigh maps of the United States place Alaska and Hawaii equally insets to the south of California. Until recently, in R this was an extremely boring task that required manually changing the latitude and longitude coordinates for these states to identify them in the correct location. Fortunately several packages are now available that have already washed the work for you. albersusa includes the usa_sf() function which returns a simple features data frame which contains adapted coordinates for Alaska and Hawaii to plot them with the mainland. It can be installed from GitHub using devtools::install_github("hrbrmstr/albersusa").

          library(albersusa) usa_sf()                  
          ## Simple feature collection with 51 features and 13 fields ## geometry type:  MULTIPOLYGON ## dimension:      XY ## bbox:           xmin: -125 ymin: 20.6 xmax: -66.9 ymax: 49.4 ## geographic CRS: WGS 84 ## First x features: ##         geo_id fips_state                 proper noun lsad census_area iso_3166_2 ## 1  0400000US04         04              Arizona           113594         AZ ## 2  0400000US05         05             Arkansas            52035         AR ## 3  0400000US06         06           California           155779         CA ## 4  0400000US08         08             Colorado           103642         CO ## 5  0400000US09         09          Connecticut             4842         CT ## 6  0400000US11         11 District of Columbia               61         DC ## 7  0400000US13         13              Georgia            57513         GA ## 8  0400000US17         17             Illinois            55519         IL ## 9  0400000US18         eighteen              Indiana            35826         IN ## ten 0400000US22         22            Louisiana            43204         LA ##      census pop_estimataes_base pop_2010 pop_2011 pop_2012 pop_2013 pop_2014 ## 1   6392017             6392310  6411999  6472867  6556236  6634997  6731484 ## two   2915918             2915958  2922297  2938430  2949300  2958765  2966369 ## 3  37253956            37254503 37336011 37701901 38062780 38431393 38802500 ## iv   5029196             5029324  5048575  5119661  5191709  5272086  5355866 ## five   3574097             3574096  3579345  3590537  3594362  3599341  3596677 ## 6    601723              601767   605210   620427   635040   649111   658893 ## 7   9687653             9688681  9714464  9813201  9919000  9994759 10097343 ## viii  12830632            12831587 12840097 12858725 12873763 12890552 12880580 ## 9   6483802             6484192  6490308  6516560  6537632  6570713  6596855 ## x  4533372             4533479  4545581  4575972  4604744  4629284  4649676 ##                          geometry ## ane  MULTIPOLYGON (((-113 37, -i... ## 2  MULTIPOLYGON (((-94 33, -94... ## iii  MULTIPOLYGON (((-120 34, -1... ## 4  MULTIPOLYGON (((-107 41, -i... ## 5  MULTIPOLYGON (((-72.4 42, -... ## half dozen  MULTIPOLYGON (((-77 38.8, -... ## 7  MULTIPOLYGON (((-84.eight 35, -... ## eight  MULTIPOLYGON (((-89.four 42.v,... ## 9  MULTIPOLYGON (((-84.8 40.4,... ## 10 MULTIPOLYGON (((-88.9 29.8,...                  
          ggplot(data = usa_sf()) +   geom_sf()                  

Add data to the map

Region boundaries serve equally the groundwork in geospatial data visualization - so at present we need to add together data. Some types of geographic information (points and symbols) are overlaid on top of the boundaries, whereas other information (fill up) are incorporated into the region layer itself.

Points

Allow's use our usa_48 map data to add some points. The airports information frame in the nycflights13 package includes geographic info on airports in the U.s..

          library(nycflights13) airports                  
          ## # A tibble: ane,458 x 8 ##    faa   proper noun                       lat    lon   alt    tz dst   tzone           ##    <chr> <chr>                    <dbl>  <dbl> <dbl> <dbl> <chr> <chr>           ##  i 04G   Lansdowne Airport         41.1  -lxxx.vi  1044    -v A     America/New_Yo… ##  2 06A   Moton Field Municipal A…  32.5  -85.vii   264    -6 A     America/Chicago ##  3 06C   Schaumburg Regional       42.0  -88.1   801    -6 A     America/Chicago ##  4 06N   Randall Airdrome           41.iv  -74.4   523    -5 A     America/New_Yo… ##  5 09J   Jekyll Isle Airport     31.1  -81.iv    11    -5 A     America/New_Yo… ##  half-dozen 0A9   Elizabethton Municipal …  36.4  -82.2  1593    -5 A     America/New_Yo… ##  7 0G6   Williams Canton Airdrome   41.v  -84.v   730    -5 A     America/New_Yo… ##  viii 0G7   Finger Lakes Regional A…  42.nine  -76.8   492    -5 A     America/New_Yo… ##  9 0P2   Shoestring Aviation Air…  39.eight  -76.6  chiliad    -v U     America/New_Yo… ## 10 0S9   Jefferson County Intl     48.1 -123.    108    -8 A     America/Los_An… ## # … with 1,448 more than rows                  

Each airport has information technology'south geographic location encoded through lat and lon. To draw these points on the map, basically nosotros describe a scatterplot with x = lon and y = lat. In fact nosotros could merely practise that:

          ggplot(airports, aes(lon, lat)) +   geom_point()                  

Allow's overlay information technology with the mapped country borders:

          ggplot(data = usa_48) +   geom_sf() +   geom_point(data = airports, aes(10 = lon, y = lat), shape = i)                  

Slight problem. Nosotros have airports listed outside of the continental United states. There are a couple means to rectify this. Unfortunately airports does not include a variable identifying state so the filter() operation is not that simple. The easiest solution is to crop the limits of the graph using coord_sf() to only show the mainland:

          ggplot(data = usa_48) +   geom_sf() +   geom_point(data = airports, aes(x = lon, y = lat), shape = 1) +   coord_sf(     xlim = c(-130, -60),     ylim = c(20, fifty)   )                  

Alternatively, nosotros can use st_as_sf() to convert airports to a simple features data frame.

          airports_sf <- st_as_sf(airports, coords = c("lon", "lat")) st_crs(airports_sf) <- 4326 # set the coordinate reference arrangement airports_sf                  
          ## Elementary feature collection with 1458 features and 6 fields ## Geometry blazon: Point ## Dimension:     XY ## Bounding box:  xmin: -177 ymin: nineteen.7 xmax: 174 ymax: 72.3 ## Geodetic CRS:  WGS 84 ## # A tibble: 1,458 x seven ##    faa   name                    alt    tz dst   tzone                  geometry ##  * <chr> <chr>                 <dbl> <dbl> <chr> <chr>               <POINT [°]> ##  i 04G   Lansdowne Airport      1044    -5 A     America/New_…      (-80.6 41.1) ##  2 06A   Moton Field Municipa…   264    -6 A     America/Chichi…      (-85.7 32.5) ##  3 06C   Schaumburg Regional     801    -6 A     America/Chic…        (-88.1 42) ##  4 06N   Randall Airport         523    -5 A     America/New_…      (-74.4 41.iv) ##  five 09J   Jekyll Isle Airport    11    -v A     America/New_…      (-81.4 31.ane) ##  6 0A9   Elizabethton Municip…  1593    -5 A     America/New_…      (-82.2 36.4) ##  seven 0G6   Williams County Airp…   730    -5 A     America/New_…      (-84.v 41.5) ##  8 0G7   Finger Lakes Regiona…   492    -v A     America/New_…      (-76.8 42.9) ##  9 0P2   Shoestring Aviation …  chiliad    -five U     America/New_…      (-76.6 39.eight) ## 10 0S9   Jefferson Canton Intl   108    -8 A     America/Los_…       (-123 48.i) ## # … with 1,448 more rows                  

coords tells st_as_sf() which columns contain the geographic coordinates of each drome. To graph the points on the map, we use a second geom_sf():

          ggplot() +   geom_sf(data = usa_48) +   geom_sf(data = airports_sf, shape = 1) +   coord_sf(     xlim = c(-130, -60),     ylim = c(20, 50)   )                  

Symbols

Nosotros tin change the size or type of symbols on the map. For instance, we can describe a bubble plot (also known as a proportional symbol map) and encode the altitude of the airport through the size aqueduct:

          ggplot(information = usa_48) +   geom_sf() +   geom_point(     information = airports, aes(x = lon, y = lat, size = alt),     fill = "grey", color = "black", alpha = .2   ) +   coord_sf(     xlim = c(-130, -60),     ylim = c(20, 50)   ) +   scale_size_area(guide = Faux)                  

Circle area is proportional to the airport'due south altitude (in feet). Or we could scale it based on the number of arriving flights in flights:

          airports_n <- flights %>%   count(dest) %>%   left_join(airports, past = c("dest" = "faa"))  ggplot(data = usa_48) +   geom_sf() +   geom_point(     information = airports_n, aes(x = lon, y = lat, size = northward),     fill up = "grey", color = "black", alpha = .2   ) +   coord_sf(     xlim = c(-130, -lx),     ylim = c(20, 50)   ) +   scale_size_area(guide = Faux)                  

airports contains a list of nearly all commercial airports in the United States. Withal flights just contains data on flights departing from New York City airports (JFK, LaGuardia, or Newark) and only services a few airports around the state.

Make full (choropleths)

Choropleth maps encode information by assigning shades of colors to divers areas on a map (e.g. countries, states, counties, zip codes). At that place are lots of ways to tweak and customize these graphs, which is by and large a good idea considering remember that colour is i of the harder-to-decode channels.

Nosotros volition continue to use the usa_48 simple features data frame and draw a choropleth for the number of strange-built-in individuals in each state. Nosotros go those files from the census_bureau folder. Let'south also normalize our measure past the full population to get the rate of strange-born individuals in the population:

          (fb_state <- hither(   "static", "data", "census_bureau",   "ACS_13_5YR_B05012_state", "ACS_13_5YR_B05012.csv" ) %>%   read_csv() %>%   mutate(rate = HD01_VD03 / HD01_VD01))                  
          ## # A tibble: 51 x 10 ##    GEO.id     GEO.id2 `GEO.brandish-labe… HD01_VD01 HD02_VD01 HD01_VD02 HD02_VD02 ##    <chr>      <chr>   <chr>                  <dbl> <lgl>         <dbl>     <dbl> ##  1 0400000US… 01      Alabama              4799277 NA          4631045      2881 ##  2 0400000US… 02      Alaska                720316 NA           669941      1262 ##  3 0400000US… 04      Arizona              6479703 NA          5609835      7725 ##  iv 0400000US… 05      Arkansas             2933369 NA          2799972      2568 ##  v 0400000US… 06      California          37659181 NA         27483342     30666 ##  half-dozen 0400000US… 08      Colorado             5119329 NA          4623809      5778 ##  vii 0400000US… 09      Connecticut          3583561 NA          3096374      5553 ##  eight 0400000US… 10      Delaware              908446 NA           831683      2039 ##  9 0400000US… 11      District of Colum…    619371 NA           534142      2022 ## x 0400000US… 12      Florida             19091156 NA         15392410     16848 ## # … with 41 more rows, and 3 more variables: HD01_VD03 <dbl>, HD02_VD03 <dbl>, ## #   rate <dbl>                  

Bring together the information

Now that we have our data, we want to describe it on the map. fb_state contains one row per state, as does usa_48. Since there is a one-to-one match between the data frames, we join the data frames together first, and so use that single data frame to depict the map. This differs from the approach to a higher place for drawing points because a betoken feature is not the same thing every bit a polygon feature. That is, there were more airports so there were states. Because the spatial data is stored in a data frame with one row per country, all nosotros need to practice is merge the information frames together on a column that uniquely identifies each row in each data frame.

          (usa_fb <- usa_48 %>%   left_join(fb_state, by = c("STATEFP" = "GEO.id2")))                  
          ## Unproblematic feature collection with 48 features and xviii fields ## geometry type:  MULTIPOLYGON ## dimension:      XY ## bbox:           xmin: -125 ymin: 24.5 xmax: -66.9 ymax: 49.4 ## geographic CRS: NAD83 ## Commencement 10 features: ##    STATEFP  STATENS    AFFGEOID GEOID STUSPS        NAME LSAD    ALAND   AWATER ## 1       01 01779775 0400000US01    01     AL     Alabama   00 ane.31e+11 4.59e+09 ## ii       05 00068085 0400000US05    05     AR    Arkansas   00 ane.35e+11 two.96e+09 ## 3       06 01779778 0400000US06    06     CA  California   00 4.03e+xi 2.05e+10 ## four       09 01779780 0400000US09    09     CT Connecticut   00 1.25e+x 1.82e+09 ## v       12 00294478 0400000US12    12     FL     Florida   00 i.39e+eleven 3.14e+ten ## half dozen       13 01705317 0400000US13    13     GA     Georgia   00 1.49e+xi 4.95e+09 ## 7       16 01779783 0400000US16    16     ID       Idaho   00 2.14e+xi 2.40e+09 ## viii       17 01779784 0400000US17    17     IL    Illinois   00 1.44e+eleven 6.20e+09 ## 9       xviii 00448508 0400000US18    18     IN     Indiana   00 9.28e+10 i.54e+09 ## 10      20 00481813 0400000US20    20     KS      Kansas   00 2.12e+eleven 1.35e+09 ##         GEO.id GEO.display-characterization HD01_VD01 HD02_VD01 HD01_VD02 HD02_VD02 ## ane  0400000US01           Alabama   4799277        NA   4631045      2881 ## 2  0400000US05          Arkansas   2933369        NA   2799972      2568 ## 3  0400000US06        California  37659181        NA  27483342     30666 ## iv  0400000US09       Connecticut   3583561        NA   3096374      5553 ## 5  0400000US12           Florida  19091156        NA  15392410     16848 ## half-dozen  0400000US13           Georgia   9810417        NA   8859747      7988 ## 7  0400000US16             Idaho   1583364        NA   1489560      2528 ## 8  0400000US17          Illinois  12848554        NA  11073828     10091 ## 9  0400000US18           Indiana   6514861        NA   6206801      4499 ## ten 0400000US20            Kansas   2868107        NA   2677007      3095 ##    HD01_VD03 HD02_VD03   rate                       geometry ## 1     168232      2881 0.0351 MULTIPOLYGON (((-88.iii 30.2,... ## 2     133397      2568 0.0455 MULTIPOLYGON (((-94.six 36.5,... ## 3   10175839     30666 0.2702 MULTIPOLYGON (((-119 33.5, ... ## 4     487187      5553 0.1360 MULTIPOLYGON (((-73.7 41.1,... ## v    3698746     16848 0.1937 MULTIPOLYGON (((-80.7 24.9,... ## 6     950670      7988 0.0969 MULTIPOLYGON (((-85.6 35, -... ## 7      93804      2528 0.0592 MULTIPOLYGON (((-117 44.4, ... ## viii    1774726     10093 0.1381 MULTIPOLYGON (((-91.v xl.2,... ## 9     308060      4500 0.0473 MULTIPOLYGON (((-88.one 37.ix,... ## 10    191100      3100 0.0666 MULTIPOLYGON (((-102 twoscore, -ane...                  

Draw the map

With the newly combined information frame, use geom_sf() and define the fill up aesthetic based on the cavalcade in usa_fb you want to visualize.

          ggplot(data = usa_fb) +   geom_sf(aes(make full = rate))                  

Bin information to discrete intervals

When creating a heatmap with a continuous variable, one must determine whether to keep the variable every bit continuous or collapse it into a series of bins with discrete colors. While keep the variable continuous is technically more than precise, the human eye cannot usually distinguish between ii colors which are very like to one some other. By converting the variable to a detached variable, you hands distinguish between the different levels. If you make up one's mind to convert a continuous variable to a discrete variable, you lot volition need to decide how to do this. While cut() is a base R function for converting continuous variables into detached values, ggplot2 offers two functions that explicitly ascertain how nosotros want to bin the numeric vector (column).

cut_interval() makes north groups with equal range:

          usa_fb %>%   mutate(rate_cut = cut_interval(rate, n = 6)) %>%   ggplot() +   geom_sf(aes(fill up = rate_cut))                  

Whereas cut_number() makes n groups with (approximately) equal numbers of observations:

          usa_fb %>%   mutate(rate_cut = cut_number(rate, n = 6)) %>%   ggplot() +   geom_sf(aes(fill = rate_cut))                  

Run into this StackOverflow thread for a more in-depth discussion on the merits of bucketizing a continuous variable and whether to use cut_interval() or cut_number().

Changing map projection

[Mercator Projection](https://xkcd.com/2082/)

Mercator Project

Representing portions of the globe on a flat surface can be challenging. Depending on how you project the map, you tin distort or emphasize sure features of the map. Fortunately, ggplot() includes the coord_sf() office which allows us to hands implement different projection methods. In society to implement coordinate transformations, you need to know the coordinate reference organisation that defines the projection method. The "easiest" approach is to provide what is known as the proj4string that defines the projection method. PROJ4 is a generic coordinate transformation software that allows you to convert betwixt projection methods. If you get actually into geospatial assay and visualization, it is helpful to acquire this system.

For our purposes here, proj4string is a graphic symbol cord in R that defines the coordinate system and includes parameters specific to a given coordinate transformation. PROJ4 includes some documentation on common projection methods that can get you started. Some project methods are relatively uncomplicated and require just the name of the project, similar for a Mercator project ("+proj=merc"):

          map_proj_base <- ggplot(data = usa_48) +   geom_sf()                  
          map_proj_base +   coord_sf(crs = "+proj=merc") +   ggtitle("Mercator projection")                  

Other coordinate systems require specification of the standard lines, or lines that define areas of the surface of the map that are tangent to the globe. These include Gall-Peters, Albers equal-area, and Lambert azimuthal.

          map_proj_base +   coord_sf(crs = "+proj=cea +lon_0=0 +lat_ts=45") +   ggtitle("Gall-Peters projection")                  

          map_proj_base +   coord_sf(crs = "+proj=aea +lat_1=25 +lat_2=l +lon_0=-100") +   ggtitle("Albers equal-area projection")                  

          map_proj_base +   coord_sf(crs = "+proj=laea +lat_0=35 +lon_0=-100") +   ggtitle("Lambert azimuthal projection")                  

Session Info

          devtools::session_info()                  
          ## ─ Session info ─────────────────────────────────────────────────────────────── ##  setting  value                        ##  version  R version 4.0.four (2021-02-15) ##  os       macOS Big Sur ten.16          ##  system   x86_64, darwin17.0           ##  ui       X11                          ##  language (EN)                         ##  collate  en_US.UTF-8                  ##  ctype    en_US.UTF-eight                  ##  tz       America/Chicago              ##  engagement     2022-07-13                   ##  ## ─ Packages ─────────────────────────────────────────────────────────────────── ##  package     * version appointment       lib source         ##  assertthat    0.2.i   2022-03-21 [2] CRAN (R iv.0.0) ##  backports     1.2.1   2022-12-09 [2] CRAN (R 4.0.2) ##  blogdown      1.iii     2022-04-14 [ii] CRAN (R four.0.2) ##  bookdown      0.22    2022-04-22 [2] CRAN (R four.0.2) ##  broom         0.seven.half-dozen   2022-04-05 [2] CRAN (R 4.0.4) ##  bslib         0.2.5   2022-05-12 [2] CRAN (R iv.0.4) ##  cachem        1.0.five   2022-05-xv [2] CRAN (R 4.0.2) ##  callr         3.vii.0   2022-04-20 [ii] CRAN (R 4.0.2) ##  cellranger    1.1.0   2022-07-27 [2] CRAN (R 4.0.0) ##  course         7.iii-19  2022-05-03 [2] CRAN (R 4.0.two) ##  classInt      0.4-three   2022-04-07 [2] CRAN (R 4.0.0) ##  cli           2.5.0   2022-04-26 [2] CRAN (R 4.0.2) ##  colorspace    2.0-ane   2022-05-04 [2] CRAN (R 4.0.2) ##  crayon        1.4.1   2022-02-08 [2] CRAN (R four.0.2) ##  DBI           1.1.one   2022-01-15 [2] CRAN (R 4.0.2) ##  dbplyr        2.one.ane   2022-04-06 [2] CRAN (R 4.0.4) ##  desc          i.3.0   2022-03-05 [2] CRAN (R 4.0.2) ##  devtools      2.iv.1   2022-05-05 [ii] CRAN (R 4.0.two) ##  digest        0.half-dozen.27  2022-ten-24 [2] CRAN (R four.0.2) ##  dplyr       * 1.0.6   2022-05-05 [2] CRAN (R 4.0.2) ##  e1071         1.7-vi   2022-03-eighteen [2] CRAN (R iv.0.two) ##  ellipsis      0.3.ii   2022-04-29 [ii] CRAN (R 4.0.2) ##  evaluate      0.14    2022-05-28 [2] CRAN (R 4.0.0) ##  fansi         0.4.ii   2022-01-15 [ii] CRAN (R 4.0.2) ##  fastmap       1.one.0   2022-01-25 [2] CRAN (R four.0.2) ##  forcats     * 0.5.1   2022-01-27 [ii] CRAN (R four.0.two) ##  fs            one.5.0   2022-07-31 [two] CRAN (R 4.0.2) ##  generics      0.1.0   2022-ten-31 [2] CRAN (R 4.0.2) ##  ggplot2     * three.3.3   2022-12-30 [2] CRAN (R iv.0.2) ##  mucilage          1.4.two   2022-08-27 [2] CRAN (R iv.0.ii) ##  gtable        0.3.0   2022-03-25 [2] CRAN (R iv.0.0) ##  haven         2.4.one   2022-04-23 [2] CRAN (R 4.0.ii) ##  here        * ane.0.1   2022-12-13 [2] CRAN (R iv.0.2) ##  hms           i.1.0   2022-05-17 [2] CRAN (R 4.0.4) ##  htmltools     0.v.1.one 2022-01-22 [2] CRAN (R iv.0.2) ##  httr          1.4.ii   2022-07-20 [2] CRAN (R 4.0.ii) ##  jquerylib     0.1.4   2022-04-26 [2] CRAN (R 4.0.two) ##  jsonlite      i.vii.2   2022-12-09 [2] CRAN (R 4.0.2) ##  KernSmooth    ii.23-20 2022-05-03 [2] CRAN (R four.0.two) ##  knitr         1.33    2022-04-24 [2] CRAN (R four.0.2) ##  lifecycle     1.0.0   2022-02-15 [ii] CRAN (R 4.0.2) ##  lubridate     one.vii.ten  2022-02-26 [2] CRAN (R 4.0.2) ##  magrittr      ii.0.1   2022-11-17 [two] CRAN (R 4.0.two) ##  memoise       2.0.0   2022-01-26 [2] CRAN (R 4.0.two) ##  modelr        0.i.eight   2022-05-nineteen [2] CRAN (R four.0.0) ##  munsell       0.5.0   2022-06-12 [2] CRAN (R 4.0.0) ##  colonnade        1.half-dozen.1   2022-05-xvi [2] CRAN (R iv.0.4) ##  pkgbuild      1.2.0   2022-12-xv [two] CRAN (R four.0.two) ##  pkgconfig     ii.0.three   2022-09-22 [2] CRAN (R 4.0.0) ##  pkgload       1.2.one   2022-04-06 [2] CRAN (R four.0.two) ##  prettyunits   1.1.1   2022-01-24 [two] CRAN (R 4.0.0) ##  processx      3.5.2   2022-04-30 [ii] CRAN (R four.0.ii) ##  proxy         0.4-25  2022-03-05 [2] CRAN (R 4.0.2) ##  ps            i.vi.0   2022-02-28 [2] CRAN (R 4.0.2) ##  purrr       * 0.3.4   2022-04-17 [ii] CRAN (R four.0.0) ##  R6            2.5.0   2022-ten-28 [2] CRAN (R iv.0.2) ##  Rcpp          1.0.half dozen   2022-01-15 [ii] CRAN (R 4.0.2) ##  readr       * one.4.0   2022-10-05 [2] CRAN (R 4.0.2) ##  readxl        1.3.i   2022-03-13 [ii] CRAN (R 4.0.0) ##  remotes       2.3.0   2022-04-01 [2] CRAN (R 4.0.2) ##  reprex        ii.0.0   2022-04-02 [2] CRAN (R 4.0.two) ##  rlang         0.4.11  2022-04-30 [2] CRAN (R 4.0.ii) ##  rmarkdown     2.8     2022-05-07 [2] CRAN (R iv.0.2) ##  rprojroot     two.0.2   2022-11-xv [ii] CRAN (R 4.0.two) ##  rstudioapi    0.thirteen    2022-11-12 [2] CRAN (R 4.0.two) ##  rvest         1.0.0   2022-03-09 [two] CRAN (R 4.0.2) ##  sass          0.4.0   2022-05-12 [2] CRAN (R iv.0.2) ##  scales        i.one.1   2022-05-11 [2] CRAN (R 4.0.0) ##  sessioninfo   i.1.1   2022-xi-05 [2] CRAN (R iv.0.0) ##  sf          * 0.nine-eight   2022-03-17 [ii] CRAN (R 4.0.2) ##  stringi       one.6.1   2022-05-10 [ii] CRAN (R 4.0.2) ##  stringr     * ane.4.0   2022-02-10 [2] CRAN (R 4.0.0) ##  testthat      3.0.2   2022-02-14 [2] CRAN (R 4.0.2) ##  tibble      * 3.1.ane   2022-04-18 [2] CRAN (R 4.0.2) ##  tidyr       * 1.i.3   2022-03-03 [2] CRAN (R iv.0.2) ##  tidyselect    one.1.1   2022-04-xxx [2] CRAN (R 4.0.two) ##  tidyverse   * one.3.one   2022-04-15 [2] CRAN (R four.0.2) ##  units         0.7-one   2022-03-16 [2] CRAN (R 4.0.2) ##  usethis       2.0.1   2022-02-10 [2] CRAN (R 4.0.2) ##  utf8          ane.2.1   2022-03-12 [2] CRAN (R four.0.2) ##  vctrs         0.three.8   2022-04-29 [2] CRAN (R iv.0.ii) ##  withr         2.4.2   2022-04-eighteen [two] CRAN (R 4.0.two) ##  xfun          0.23    2022-05-15 [ii] CRAN (R 4.0.two) ##  xml2          1.iii.ii   2022-04-23 [2] CRAN (R iv.0.0) ##  yaml          2.2.1   2022-02-01 [ii] CRAN (R 4.0.0) ##  ## [1] /Users/soltoffbc/Library/R/iv.0/library ## [2] /Library/Frameworks/R.framework/Versions/iv.0/Resource/library                  

Source: https://cfss.uchicago.edu/notes/vector-maps/

Posted by: baxterressat.blogspot.com

0 Response to "How To Draw A Map With R"

Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel