get_brmap: Get Brazilian maps from different geographic levels

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/get_brmap.R

Description

Turn available to manipulation brazilian maps in various type of geographic levels. The maps are from IBGE (Instituto Brasileiro de Geografia e Estat<c3><ad>stica) and refers to the administrative configurations of 2016.

Usage

1
2
3
get_brmap(geo = c("Brazil","Region","State","MesoRegion","MicroRegion","City"),
                 geo.filter = NULL,
                 class = c("sf", "SpatialPolygonsDataFrame", "data.frame"))

Arguments

geo

A string value with geographic levels of interest

geo.filter

A named list object with the specific item of the geographic level or all itens of a determined higher geografic level

class

The class of the object to be returned

Details

The geo argument can be one of "Brazil", "Region", "State", "MesoRegion", "MicroRegion" and "City". 'geo.filter' lists must be named with the same characters.

Value

The function returns a 'sf', 'SpatialPolygonsDataFrame' or 'data.frame' object depending of the 'class' argument informed

Author(s)

Renato Prado Siqueira <rpradosiqueira@gmail.com>

See Also

join_data

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
## Retrieving the map from the State of Rio de Janeiro
rio_map <- get_brmap(geo = "State",
                     geo.filter = list(State = 33),
                     class = "sf")
plot_brmap(rio_map)

## Obtaining the municipalities maps from Midwest Region
cities_map <- get_brmap(geo = "City",
                        geo.filter = list(Region = 5),
                        class = "sf")
plot_brmap(cities_map)

brazilmaps documentation built on May 2, 2019, 3:04 a.m.