Spatial data package for Ethiopia
---
title: "README"
output: html_document
---
# mapEthiopia
`mapEthiopia` is an R spatial data package providing easy access to
geospatial datasets for Ethiopia.
The package provides simple getter functions that return analysis-ready
spatial objects, including vector, raster, and tabular datasets.
## Installation
Install the development version from GitHub:
```r
install.packages("remotes")
remotes::install_github("yourusername/mapEthiopia")
```
Load the package:
```r
library(mapEthiopia)
```
## Available datasets
`mapEthiopia` provides access to:
### Administrative data
- National boundary
- Regions
- Zones
- Woredas
- Administrative capitals
### Environmental datasets
- Digital Elevation Model
- CHIRPS rainfall
- TerraClimate climate variables
- ESA WorldCover land cover
- WorldPop population rasters
### Socioeconomic and infrastructure data
- Population statistics
- Financial service locations
- Aerial imagery coverage
- Hydrographic basins
## Basic examples
### Ethiopia boundary
```r
library(mapEthiopia)
ethiopia <- eth_get_country()
plot(ethiopia["adm0_name"])
```
### Administrative regions
```r
regions <- eth_get_regions()
plot(regions["adm1_name"])
```
### Population by woreda
```r
population <- eth_join_population(
level = 3
)
plot(population["Total"])
```
## Dynamic datasets
Large datasets are not stored inside the package. Instead, they are
downloaded when required.
Example:
```r
rain <- eth_get_rainfall(
year = 2020,
month = 1:12
)
terra::plot(rain)
```
Available dynamic datasets include:
- CHIRPS rainfall
- TerraClimate climate variables
- ESA WorldCover land cover
- WorldPop population estimates
## Dataset discovery
List available datasets:
```r
eth_list_datasets()
```
Search datasets:
```r
eth_search_datasets("population")
```
Retrieve metadata:
```r
eth_get_metadata("eth_admin0")
```
## Documentation
See the package vignette:
```r
vignette("mapEthiopia-intro")
```
## License
MIT License.