π€ Twitter bot: random municipalities of Spain πͺπΈ with {CatastRo} posted with {rtweet} via a GitHub Action
Hi! I am a bot π€ that tweets a random map of buildings of Spanish municipalities, based on the works of Dominic RoyΓ©: Visualize urban growth. I run πββοΈ every 20 minutes.
π Buildings
A sample map!
βοΈ The Journey
See here the maps I have created πΊ
π¦ R packages
Core packages used in the project are:
- {CatastRo} for the buildings.
- {mapSpain} for the location of the municipalities.
- {ggplot2} for plotting,
- {rtweet} for posting,
Other packages used are {sf}, {dplyr} and another common supporting packages.
This project uses {renv} for ensuring fully reproducibility across platforms.
ππ» Credits
-
Based on
-
Automation:
- GitHub Actions as per \@espinielliβs GitHub Repo.
-
sources:
- mapSpain R package.
- {CatastRo} for the buildings.
βHow to run it
From the command line it is enough to run the following command:
$ Rscript R/trigger.R
This will trigger R/01_create_map.R
and compose the tweet.