Package 'malawi'

Title: Datasets for Designing Surveys in Malawi
Description: Designing surveys require relevant datasets to be used as basis for sample size calculations, sampling design, survey planning/logistics and survey implementation. These include datasets on population, lists of sampling clusters, map datasets for spatial sampling, and previous survey datasets that can be used for estimating indicator variance and design effects. This package contains relevant datasets for use in designing surveys in Malawi.
Authors: Ernest Guevarra [aut, cre]
Maintainer: Ernest Guevarra <[email protected]>
License: GPL (>= 3)
Version: 0.0.0.9000
Built: 2024-11-11 05:30:32 UTC
Source: https://github.com/spatialworks/malawi

Help Index


Download Malawi administrative boundaries shapefiles from Humanitarian Data Exchange

Description

Download Malawi administrative boundaries shapefiles from Humanitarian Data Exchange

Usage

download_boundaries_shapefiles(id, .unzip = TRUE)

Arguments

id

Character vector for unique identifier of administrative boundaries data for Malawi from Humanitarian Data Exchange

.unzip

Logical. Should zip file be unzipped and extracted? Default to TRUE

Value

If .unzip, list of shapefiles within the downloaded zip file else path to downloaded zip file. (Invisible) Shapefiles zip file downloaded to specified folder.

Examples

download_boundaries_shapefiles(id = "cod-ab-mwi")

Download Malawi livelihood zones shapefiles from Humanitarian Data Exchange

Description

Download Malawi livelihood zones shapefiles from Humanitarian Data Exchange

Usage

download_lhz_shapefiles(.unzip = TRUE)

Arguments

.unzip

Logical. Should zip file be unzipped and extracted? Default to TRUE

Value

If .unzip, list of shapefiles within the downloaded zip file else path to downloaded zip file. (Invisible) Shapefiles zip file downloaded to specified folder.

Examples

download_lhz_shapefiles()

Get administrative boundaries layer name

Description

Get administrative boundaries layer name

Usage

get_boundaries_name(files, adm = NULL)

Arguments

files

List of shapefiles within a downloaded zip file

adm

Integer. Administrative level required. Either 0 for country, 1 for regions, 2 for districts, or 3 for traditional authority areas.

Value

Layer name for specified administrative level boundary

Examples

get_boundaries_name(
  download_boundaries_shapefiles(id = "cod-ab-mwi"), adm = 0
)

Retrieve Malawi boundary layer

Description

Retrieve Malawi boundary layer

Usage

get_boundary(id, adm = NULL)

Arguments

id

Character vector for unique identifier of administrative boundaries data for Malawi from Humanitarian Data Exchange

adm

Integer. Administrative level required. Either 0 for country, 1 for regions, 2 for districts, or 3 for traditional authority areas.

Value

An sf object for specific boundary of Malawi

Examples

get_boundary(id = "cod-ab-mwi", adm = 0)

Retrieve Malawi country boundaries

Description

Retrieve Malawi country boundaries

Usage

get_country(id)

Arguments

id

Character vector for unique identifier of administrative boundaries data for Malawi from Humanitarian Data Exchange

Value

An sf object for the country borders of Malawi

Examples

get_country(id = "cod-ab-mwi")

Retrieve Malawi districts boundaries

Description

Retrieve Malawi districts boundaries

Usage

get_districts(id)

Arguments

id

Character vector for unique identifier of administrative boundaries data for Malawi from Humanitarian Data Exchange

Value

An sf object for the districts borders of Malawi

Examples

get_districts(id = "cod-ab-mwi")

Retrieve Malawi livelihood zones

Description

Retrieve Malawi livelihood zones

Usage

get_lhz(layer = get_lhz_name())

Arguments

layer

Name of layer for livelihood zones

Value

An sf object for the livelihood zones of Malawi

Examples

get_lhz()

Get livelihoods zones layer name

Description

Get livelihoods zones layer name

Usage

get_lhz_name(files = download_lhz_shapefiles())

Arguments

files

List of shapefiles within a downloaded zip file

Value

Layer name for livelihood zones shapefile

Examples

get_lhz_name()

Retrieve Malawi regions boundaries

Description

Retrieve Malawi regions boundaries

Usage

get_regions(id)

Arguments

id

Character vector for unique identifier of administrative boundaries data for Malawi from Humanitarian Data Exchange

Value

An sf object for the regions borders of Malawi

Examples

get_regions(id = "cod-ab-mwi")

Retrieve Malawi traditional authority areas boundaries

Description

Retrieve Malawi traditional authority areas boundaries

Usage

get_ta_areas(id)

Arguments

id

Character vector for unique identifier of administrative boundaries data for Malawi from Humanitarian Data Exchange

Value

An sf object for the traditional authority areas borders of Malawi

Examples

get_ta_areas(id = "cod-ab-mwi")