| read_schools | R Documentation |
Data comes from the School Census and Catalogue of Schools, organized by the
National Institute for Educational Studies and Research Anisio Teixeira (INEP).
More information available at https://www.gov.br/inep/pt-br/acesso-a-informacao/dados-abertos/inep-data/catalogo-de-escolas/.
The spatial coordinates used in geobr are a combination of the coordinates
produced by the original data producer and the coordinates found via geocoding
with the geocodebr package https://CRAN.R-project.org/package=geocodebr.
Whenever the distance between the coordinates from both sources is smaller than
800 meters, geobr uses coordinates from the data producer. When the distance
between the two sources is greater than 800 meters and the results from
geocodebr have a precision level finer than 800 meters, geobr uses the
coordinates from geocodebr. When the coordinates from the original source are
missing, geobr also uses geocodebr coordinates, regardless of precision level.
The source of the spatial coordinates used in each observation is registered
in the data in a specific column coords_source. Additional columns
indicating the precision level of geocodebr geocoding are also included in
the data.
read_schools(
year,
code_muni = "all",
output = "sf",
showProgress = TRUE,
cache = TRUE,
verbose = TRUE
)
year |
Numeric. Year of the data in YYYY format. It defaults to |
code_muni |
The 7-digit code of a municipality. If |
output |
String. Type of object returned by the function. Defaults to
|
showProgress |
Logical. Defaults to |
cache |
Logical. Whether the function should read the data cached
locally, which is faster. Defaults to |
verbose |
A logical. If |
An "sf" "data.frame" OR an ArrowObject
# Read all schools in the country
s <- read_schools(year = 2020)
# Read all schools in a given state
s <- read_schools(
year = 2020,
code_muni = "AC"
)
# Read all schools in a given municipality
s <- read_schools(
year = 2020,
code_muni = 1200401
)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.