Browse Source

restored missing rds files

master
Bob Rudis 7 years ago
parent
commit
9bd91bd09a
No known key found for this signature in database GPG Key ID: 1D7529BE14E2BBA9
  1. 1
      .travis.yml
  2. 11
      README.Rmd
  3. 79
      README.md
  4. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-1.png
  5. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-10.png
  6. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-11.png
  7. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-12.png
  8. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-13.png
  9. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-14.png
  10. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-15.png
  11. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-16.png
  12. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-17.png
  13. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-18.png
  14. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-19.png
  15. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-2.png
  16. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-3.png
  17. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-4.png
  18. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-5.png
  19. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-6.png
  20. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-7.png
  21. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-8.png
  22. BIN
      README_files/figure-markdown_github/unnamed-chunk-3-9.png
  23. 6
      albersusa.Rproj
  24. BIN
      inst/extdata/counties.rda
  25. BIN
      inst/extdata/states.rda
  26. 4
      tests/testthat/test-albersusa.R

1
.travis.yml

@ -4,7 +4,6 @@ sudo: required
apt_packages: apt_packages:
- binutils - binutils
- libproj-dev
- gdal-bin - gdal-bin
- libgdal1-dev - libgdal1-dev
- netcdf-bin - netcdf-bin

11
README.Rmd

@ -53,10 +53,10 @@ us <- usa_composite()
dplyr::glimpse(us@data) dplyr::glimpse(us@data)
plot(us) plot(us, lwd=0.25)
us <- usa_composite("laea") us <- usa_composite("laea")
plot(us) plot(us, lwd=0.25)
us <- usa_composite() us <- usa_composite()
us_map <- fortify(us, region="name") us_map <- fortify(us, region="name")
@ -87,17 +87,18 @@ gg +
color="white", size=0.1) + color="white", size=0.1) +
coord_proj(us_laea_proj) + coord_proj(us_laea_proj) +
scale_fill_viridis(name="2014 Populaton Estimates", labels=comma) + scale_fill_viridis(name="2014 Populaton Estimates", labels=comma) +
theme(legend.position="right") theme(legend.position="top",
legend.key.width=unit(3, "lines"))
us <- counties_composite() us <- counties_composite()
dplyr::glimpse(us@data) dplyr::glimpse(us@data)
plot(us) plot(us, lwd=0.25)
us <- counties_composite("laea") us <- counties_composite("laea")
plot(us) plot(us, lwd=0.25)
us <- counties_composite() us <- counties_composite()
us_map <- fortify(us, region="fips") us_map <- fortify(us, region="fips")

79
README.md

@ -52,28 +52,30 @@ dplyr::glimpse(us@data)
``` ```
## Observations: 51 ## Observations: 51
## Variables: 11 ## Variables: 13
## $ geo_id (chr) "0400000US04", "0400000US05", "0400000US06", "0400000US08", "0400000US09", "0400000US11... ## $ geo_id <chr> "0400000US04", "0400000US05", "0400000US06", "0400000US08", "0400000US09", "0400000US11...
## $ fips_state (chr) "04", "05", "06", "08", "09", "11", "13", "17", "18", "22", "27", "28", "30", "35", "38... ## $ fips_state <chr> "04", "05", "06", "08", "09", "11", "13", "17", "18", "22", "27", "28", "30", "35", "38...
## $ name (chr) "Arizona", "Arkansas", "California", "Colorado", "Connecticut", "District of Columbia",... ## $ name <chr> "Arizona", "Arkansas", "California", "Colorado", "Connecticut", "District of Columbia",...
## $ iso_3166_2 (chr) "AZ", "AR", "CA", "CO", "CT", "DC", "GA", "IL", "IN", "LA", "MN", "MS", "MT", "NM", "ND... ## $ lsad <chr> "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "",...
## $ census (dbl) 6392017, 2915918, 37253956, 5029196, 3574097, 601723, 9687653, 12830632, 6483802, 45333... ## $ census_area <dbl> 113594.084, 52035.477, 155779.220, 103641.888, 4842.355, 61.048, 57513.485, 55518.930, ...
## $ pop_estimataes_base (dbl) 6392310, 2915958, 37254503, 5029324, 3574096, 601767, 9688681, 12831587, 6484192, 45334... ## $ iso_3166_2 <chr> "AZ", "AR", "CA", "CO", "CT", "DC", "GA", "IL", "IN", "LA", "MN", "MS", "MT", "NM", "ND...
## $ pop_2010 (dbl) 6411999, 2922297, 37336011, 5048575, 3579345, 605210, 9714464, 12840097, 6490308, 45455... ## $ census <int> 6392017, 2915918, 37253956, 5029196, 3574097, 601723, 9687653, 12830632, 6483802, 45333...
## $ pop_2011 (dbl) 6472867, 2938430, 37701901, 5119661, 3590537, 620427, 9813201, 12858725, 6516560, 45759... ## $ pop_estimataes_base <int> 6392310, 2915958, 37254503, 5029324, 3574096, 601767, 9688681, 12831587, 6484192, 45334...
## $ pop_2012 (dbl) 6556236, 2949300, 38062780, 5191709, 3594362, 635040, 9919000, 12873763, 6537632, 46047... ## $ pop_2010 <int> 6411999, 2922297, 37336011, 5048575, 3579345, 605210, 9714464, 12840097, 6490308, 45455...
## $ pop_2013 (dbl) 6634997, 2958765, 38431393, 5272086, 3599341, 649111, 9994759, 12890552, 6570713, 46292... ## $ pop_2011 <int> 6472867, 2938430, 37701901, 5119661, 3590537, 620427, 9813201, 12858725, 6516560, 45759...
## $ pop_2014 (dbl) 6731484, 2966369, 38802500, 5355866, 3596677, 658893, 10097343, 12880580, 6596855, 4649... ## $ pop_2012 <int> 6556236, 2949300, 38062780, 5191709, 3594362, 635040, 9919000, 12873763, 6537632, 46047...
## $ pop_2013 <int> 6634997, 2958765, 38431393, 5272086, 3599341, 649111, 9994759, 12890552, 6570713, 46292...
## $ pop_2014 <int> 6731484, 2966369, 38802500, 5355866, 3596677, 658893, 10097343, 12880580, 6596855, 4649...
``` r ``` r
plot(us) plot(us, lwd=0.25)
``` ```
<img src="README_files/figure-markdown_github/unnamed-chunk-3-1.png" width="672" /> <img src="README_files/figure-markdown_github/unnamed-chunk-3-1.png" width="672" />
``` r ``` r
us <- usa_composite("laea") us <- usa_composite("laea")
plot(us) plot(us, lwd=0.25)
``` ```
<img src="README_files/figure-markdown_github/unnamed-chunk-3-2.png" width="672" /> <img src="README_files/figure-markdown_github/unnamed-chunk-3-2.png" width="672" />
@ -86,8 +88,17 @@ gg <- ggplot()
gg <- gg + geom_map(data=us_map, map=us_map, gg <- gg + geom_map(data=us_map, map=us_map,
aes(x=long, y=lat, map_id=id), aes(x=long, y=lat, map_id=id),
color="#2b2b2b", size=0.1, fill=NA) color="#2b2b2b", size=0.1, fill=NA)
```
## Warning: Ignoring unknown aesthetics: x, y
``` r
gg <- gg + theme_map() gg <- gg + theme_map()
```
## Warning: `panel.margin` is deprecated. Please use `panel.spacing` property instead
``` r
gg + coord_map() gg + coord_map()
``` ```
@ -136,7 +147,8 @@ gg +
color="white", size=0.1) + color="white", size=0.1) +
coord_proj(us_laea_proj) + coord_proj(us_laea_proj) +
scale_fill_viridis(name="2014 Populaton Estimates", labels=comma) + scale_fill_viridis(name="2014 Populaton Estimates", labels=comma) +
theme(legend.position="right") theme(legend.position="top",
legend.key.width=unit(3, "lines"))
``` ```
<img src="README_files/figure-markdown_github/unnamed-chunk-3-10.png" width="672" /> <img src="README_files/figure-markdown_github/unnamed-chunk-3-10.png" width="672" />
@ -148,26 +160,25 @@ dplyr::glimpse(us@data)
``` ```
## Observations: 3,143 ## Observations: 3,143
## Variables: 9 ## Variables: 8
## $ fips (chr) "01001", "01009", "01017", "01021", "01033", "01045", "01051", "01065", "01079", "01083", "0109... ## $ fips <chr> "01001", "01009", "01017", "01021", "01033", "01045", "01051", "01065", "01079", "01083", "0109...
## $ state_fips (chr) "01", "01", "01", "01", "01", "01", "01", "01", "01", "01", "01", "01", "01", "05", "05", "06",... ## $ state_fips <chr> "01", "01", "01", "01", "01", "01", "01", "01", "01", "01", "01", "01", "01", "05", "05", "06",...
## $ county_fips (chr) "001", "009", "017", "021", "033", "045", "051", "065", "079", "083", "099", "107", "121", "141... ## $ county_fips <chr> "001", "009", "017", "021", "033", "045", "051", "065", "079", "083", "099", "107", "121", "141...
## $ name (chr) "Autauga", "Blount", "Chambers", "Chilton", "Colbert", "Dale", "Elmore", "Hale", "Lawrence", "L... ## $ name <chr> "Autauga", "Blount", "Chambers", "Chilton", "Colbert", "Dale", "Elmore", "Hale", "Lawrence", "L...
## $ lsad (chr) "County", "County", "County", "County", "County", "County", "County", "County", "County", "Coun... ## $ lsad <chr> "County", "County", "County", "County", "County", "County", "County", "County", "County", "Coun...
## $ census_area (dbl) 594.436, 644.776, 596.531, 692.854, 592.619, 561.150, 618.485, 643.943, 690.678, 559.936, 1025.... ## $ census_area <dbl> 594.436, 644.776, 596.531, 692.854, 592.619, 561.150, 618.485, 643.943, 690.678, 559.936, 1025....
## $ state (chr) "Alabama", "Alabama", "Alabama", "Alabama", "Alabama", "Alabama", "Alabama", "Alabama", "Alabam... ## $ state <chr> "Alabama", "Alabama", "Alabama", "Alabama", "Alabama", "Alabama", "Alabama", "Alabama", "Alabam...
## $ iso_3166_2 (chr) "AL", "AL", "AL", "AL", "AL", "AL", "AL", "AL", "AL", "AL", "AL", "AL", "AL", "AR", "AR", "CA",... ## $ iso_3166_2 <chr> "AL", "AL", "AL", "AL", "AL", "AL", "AL", "AL", "AL", "AL", "AL", "AL", "AL", "AR", "AR", "CA",...
## $ population (dbl) 54590, 57466, 34228, 43611, 54451, 50129, 79330, 15750, 34148, 83313, 22993, 19646, 82194, 1722...
``` r ``` r
plot(us) plot(us, lwd=0.25)
``` ```
<img src="README_files/figure-markdown_github/unnamed-chunk-3-11.png" width="672" /> <img src="README_files/figure-markdown_github/unnamed-chunk-3-11.png" width="672" />
``` r ``` r
us <- counties_composite("laea") us <- counties_composite("laea")
plot(us) plot(us, lwd=0.25)
``` ```
<img src="README_files/figure-markdown_github/unnamed-chunk-3-12.png" width="672" /> <img src="README_files/figure-markdown_github/unnamed-chunk-3-12.png" width="672" />
@ -180,8 +191,17 @@ gg <- ggplot()
gg <- gg + geom_map(data=us_map, map=us_map, gg <- gg + geom_map(data=us_map, map=us_map,
aes(x=long, y=lat, map_id=id), aes(x=long, y=lat, map_id=id),
color="#2b2b2b", size=0.1, fill=NA) color="#2b2b2b", size=0.1, fill=NA)
```
## Warning: Ignoring unknown aesthetics: x, y
``` r
gg <- gg + theme_map() gg <- gg + theme_map()
```
## Warning: `panel.margin` is deprecated. Please use `panel.spacing` property instead
``` r
gg + coord_map() gg + coord_map()
``` ```
@ -232,7 +252,7 @@ library(testthat)
date() date()
``` ```
## [1] "Tue Mar 29 15:08:54 2016" ## [1] "Mon Dec 19 16:02:00 2016"
``` r ``` r
test_dir("tests/") test_dir("tests/")
@ -240,3 +260,6 @@ test_dir("tests/")
## testthat results ======================================================================================================== ## testthat results ========================================================================================================
## OK: 6 SKIPPED: 0 FAILED: 0 ## OK: 6 SKIPPED: 0 FAILED: 0
##
## DONE ===================================================================================================================
## You rock!

BIN
README_files/figure-markdown_github/unnamed-chunk-3-1.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 122 KiB

After

Width:  |  Height:  |  Size: 114 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-10.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 138 KiB

After

Width:  |  Height:  |  Size: 177 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-11.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 283 KiB

After

Width:  |  Height:  |  Size: 273 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-12.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 271 KiB

After

Width:  |  Height:  |  Size: 296 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-13.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 370 KiB

After

Width:  |  Height:  |  Size: 368 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-14.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 348 KiB

After

Width:  |  Height:  |  Size: 348 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-15.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 326 KiB

After

Width:  |  Height:  |  Size: 325 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-16.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 341 KiB

After

Width:  |  Height:  |  Size: 341 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-17.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 340 KiB

After

Width:  |  Height:  |  Size: 340 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-18.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 332 KiB

After

Width:  |  Height:  |  Size: 333 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-19.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 328 KiB

After

Width:  |  Height:  |  Size: 328 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-2.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 134 KiB

After

Width:  |  Height:  |  Size: 122 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-3.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 148 KiB

After

Width:  |  Height:  |  Size: 143 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-4.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 140 KiB

After

Width:  |  Height:  |  Size: 139 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-5.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 131 KiB

After

Width:  |  Height:  |  Size: 128 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-6.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 138 KiB

After

Width:  |  Height:  |  Size: 136 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-7.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 137 KiB

After

Width:  |  Height:  |  Size: 137 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-8.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 135 KiB

After

Width:  |  Height:  |  Size: 134 KiB

BIN
README_files/figure-markdown_github/unnamed-chunk-3-9.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 134 KiB

After

Width:  |  Height:  |  Size: 133 KiB

6
albersusa.Rproj

@ -1,8 +1,8 @@
Version: 1.0 Version: 1.0
RestoreWorkspace: Default RestoreWorkspace: No
SaveWorkspace: Default SaveWorkspace: No
AlwaysSaveHistory: Default AlwaysSaveHistory: No
EnableCodeIndexing: Yes EnableCodeIndexing: Yes
UseSpacesForTab: Yes UseSpacesForTab: Yes

BIN
inst/extdata/counties.rda

Binary file not shown.

BIN
inst/extdata/states.rda

Binary file not shown.

4
tests/testthat/test-albersusa.R

@ -7,8 +7,8 @@ test_that("we can do something", {
expect_that(us, is_a("SpatialPolygonsDataFrame")) expect_that(us, is_a("SpatialPolygonsDataFrame"))
expect_that(cty, is_a("SpatialPolygonsDataFrame")) expect_that(cty, is_a("SpatialPolygonsDataFrame"))
expect_that(dim(us), equals(c(51, 11))) expect_that(dim(us), equals(c(51, 13)))
expect_that(dim(cty), equals(c(3143, 9))) expect_that(dim(cty), equals(c(3143, 8)))
expect_that(length(us@polygons), equals(51)) expect_that(length(us@polygons), equals(51))
expect_that(length(cty@polygons), equals(3143)) expect_that(length(cty@polygons), equals(3143))

Loading…
Cancel
Save