-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
3288881
commit c994827
Showing
9 changed files
with
2,670 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,3 +3,4 @@ | |
.RData | ||
.Ruserdata | ||
*.gpkg | ||
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
/.quarto/ |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
--- | ||
format: gfm | ||
--- | ||
|
||
```{bash} | ||
#| eval: false | ||
# Get data from the web | ||
gh release | ||
``` | ||
|
||
|
||
```{r} | ||
#| eval: false | ||
piggyback::pb_list(repo = "itsleeds/atumie") | ||
piggyback::pb_download("zones_test.gpkg", repo = "itsleeds/atumie") | ||
piggyback::pb_download("social_grid.gpkg", repo = "itsleeds/atumie") | ||
piggyback::pb_upload("zones_test.gpkg") | ||
piggyback::pb_upload("social_grid.gpkg") | ||
# Get urls from v0.0.5 release: | ||
url_zones = "https://github.com/Robinlovelace/simodels/releases/download/v0.0.5/zones_test.gpkg" | ||
f_zones = basename(url_zones) | ||
download.file(url_zones, f_zones) | ||
url_grid = "https://github.com/Robinlovelace/simodels/releases/download/v0.0.5/social_grid.gpkg" | ||
download.file(url_grid, basename(url_grid)) | ||
``` | ||
|
||
```{r} | ||
url_zones = "https://github.com/Robinlovelace/simodels/releases/download/v0.0.5/zones_test.gpkg" | ||
zones = sf::read_sf(url_zones) | ||
url_grid = "https://github.com/Robinlovelace/simodels/releases/download/v0.0.5/social_grid.gpkg" | ||
grid = sf::read_sf(url_grid) | ||
``` | ||
|
||
```{r} | ||
devtools::load_all() | ||
od = si_to_od(zones, grid) | ||
``` | ||
|
||
```{r} | ||
zonesg = sf::st_sf( | ||
sf::st_drop_geometry(zones), | ||
geometry = zones$geom | ||
) | ||
gridg = sf::st_sf( | ||
sf::st_drop_geometry(grid), | ||
geometry = grid$geom | ||
) | ||
odg = si_to_od(zonesg, gridg) | ||
gridd = gridg[!duplicated(gridg$grid_id), ] | ||
odg = si_to_od(zonesg, gridd) | ||
``` | ||
|
||
|
||
```{r} | ||
od = od::points_to_od(zones, grid) | ||
``` |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
/.quarto/ | ||
_extensions/ | ||
*.tex |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
|
||
@article{wilson_family_1971, | ||
title = {A family of spatial interaction models, and associated developments}, | ||
author = {Wilson, AG}, | ||
year = {1971}, | ||
date = {1971}, | ||
journal = {Environment and Planning}, | ||
pages = {1{\textendash}32}, | ||
volume = {3}, | ||
number = {January}, | ||
note = {Citation Key: wilson{\_}family{\_}1971} | ||
} | ||
|
||
@book{boyce_forecasting_2015, | ||
title = {Forecasting Urban Travel: Past, Present and Future}, | ||
author = {Boyce, David E. and Williams, Huw C. W. L.}, | ||
year = {2015}, | ||
month = {02}, | ||
date = {2015-02-27}, | ||
publisher = {Edward Elgar Publishing}, | ||
note = {Citation Key: boyce{\_}forecasting{\_}2015}, | ||
langid = {en} | ||
} | ||
|
||
@article{simini_universal_2012, | ||
title = {A universal model for mobility and migration patterns}, | ||
author = {Simini, Filippo and {González}, Marta C and Maritan, Amos and {Barabási}, {Albert-László}}, | ||
year = {2012}, | ||
month = {02}, | ||
date = {2012-02}, | ||
journal = {Nature}, | ||
pages = {8{\textendash}12}, | ||
doi = {10.1038/nature10856}, | ||
url = {https://doi.org/10.1038/nature10856}, | ||
note = {Citation Key: simini{\_}universal{\_}2012} | ||
} | ||
|
||
@article{lenormand_systematic_2016, | ||
title = {Systematic comparison of trip distribution laws and models}, | ||
author = {Lenormand, Maxime and Bassolas, Aleix and Ramasco, {José J.}}, | ||
year = {2016}, | ||
month = {02}, | ||
date = {2016-02-01}, | ||
journal = {Journal of Transport Geography}, | ||
pages = {158--169}, | ||
volume = {51}, | ||
doi = {10.1016/j.jtrangeo.2015.12.008}, | ||
url = {https://www.sciencedirect.com/science/article/pii/S0966692315002422}, | ||
note = {Citation Key: lenormand{\_}systematic{\_}2016}, | ||
langid = {en} | ||
} | ||
|
||
@article{dennett_modelling_2018, | ||
title = {Modelling population flows using spatial interaction models}, | ||
author = {Dennett, Adam}, | ||
year = {2018}, | ||
month = {11}, | ||
date = {2018-11-11}, | ||
journal = {Australian Population Studies}, | ||
pages = {33--58}, | ||
volume = {2}, | ||
number = {2}, | ||
doi = {10.37970/aps.v2i2.38}, | ||
url = {https://www.australianpopulationstudies.org/index.php/aps/article/view/38}, | ||
note = {Number: 2 | ||
Citation Key: dennett{\_}modelling{\_}2018}, | ||
langid = {en} | ||
} |
Oops, something went wrong.