Title: | Access Data from the Public Security Institute of the State of Rio De Janeiro |
Version: | 1.1.2 |
Description: | Allows access to data from the Rio de Janeiro Public Security Institute (ISP), such as criminal statistics, data on gun seizures and femicide. The package also contains the spatial data of Pacifying Police Units (UPPs) and Integrated Public Safety Regions, Areas and Circumscriptions. |
License: | MIT + file LICENSE |
Depends: | R (≥ 2.10) |
Encoding: | UTF-8 |
RoxygenNote: | 7.2.1 |
Suggests: | testthat (≥ 3.0.0) |
Config/testthat/edition: | 3 |
LazyData: | true |
LazyDataCompression: | xz |
Imports: | curl, dplyr, janitor, openxlsx, readr, sf |
NeedsCompilation: | no |
Packaged: | 2023-05-24 10:57:54 UTC; igorl |
Author: | Igor Laltuf |
Maintainer: | Igor Laltuf <igorlaltuf@gmail.com> |
Repository: | CRAN |
Date/Publication: | 2023-05-24 11:20:08 UTC |
Access the statistics about bicycle theft of the State of Rio de Janeiro
Description
Returns monthly data on police occurrences involving bicycle theft in the State of Rio de Janeiro in the form of a dataframe.
Usage
bicycle_theft()
Value
a dataframe
Examples
## Not run: bicycle_theft()
Access data from car fleet
Description
Returns data about car fleet in State of Rio de Janeiro in the form of a dataframe.
Usage
car_fleet(by)
Arguments
by |
"month" or "year". character. |
Value
a dataframe.
Examples
## Not run: car_fleet(by = "month")
Access the public security statistics about crimes against life in the State of Rio de Janeiro
Description
Returns monthly data about crimes against life in the State of Rio de Janeiro in the form of a dataframe.
Usage
crimes_against_life(type)
Arguments
type |
allows you to select the type of violent crime: "femicide", "violent_lethality", "violent_lethality_elucidation_rate" or "officers_killed_on_duty". character. |
Details
The data available are on femicide, violent lethality, the rate of elucidation of cases of violent lethality or death of police officers on duty.
Value
a dataframe
Examples
## Not run: crimes_against_life(type = "femicide")
Access data from gun seizure in State of Rio de Janeiro
Description
Returns monthly data about gun seizure in State of Rio de Janeiro in the form of a dataframe.
Usage
gun_seizure(gun_type)
Arguments
gun_type |
selects the gun type: "firearms" or "edged_weapons". character. |
Value
a dataframe
Examples
gun_seizure(gun_type = "firearms")
Access historical data from seizure of firearms in State of Rio de Janeiro
Description
Returns monthly historical data about seizure of firearms in State of Rio de Janeiro in the form of a dataframe.
Usage
gun_seizure_historical(by)
Arguments
by |
selects the spatial division of the data: "cisp" or "state". character. |
Details
Data availability from 2000 to 2006 for the State and from 2003 to 2006 for the Police Station Area (also called CISP).
Value
a dataframe
Examples
## Not run: gun_seizure_historical(by = "cisp")
Access the public security statistics of the State of Rio de Janeiro by month
Description
Returns monthly data on police occurrences in the State of Rio de Janeiro in the form of a dataframe.
Usage
monthly_stats(by, value = "standard")
Arguments
by |
selects the spatial division of the data. It might be: "cisp", "municipality" or "state". character. |
value |
allows you to choose whether the values will be in absolute numbers ("standard") or per 100,000 inhabitants ("per_100k"). character. |
Details
To see the dictionary of variables, use the function monthly_stats_dictionary().
Value
a dataframe
Examples
monthly_stats(by = "cisp")
Access the dictionaries of public security statistics of the State of Rio de Janeiro by month
Description
Returns the data dictionary of the police occurrences in the State of Rio de Janeiro in the form of a dataframe.
Usage
monthly_stats_dictionary(by, value = "standard")
Arguments
by |
selects the spatial division of the dictionary. It might be: "cisp", "municipality" or "state". character. |
value |
selects the type of value: absolute numbers ("standard") or per 100,000 inhabitants ("per_100k"). character. |
Value
a dataframe
Examples
## Not run: monthly_stats_dictionary(by = "state", value = "per_100k")
Access population data
Description
Returns data about population by state, municipality, CISP (the same as police station area) or Pacifying Police Unit.
Usage
population(data)
Arguments
data |
selects the data: "cisp_monthly", "cisp_yearly", "muni_monthly", "muni_yearly", "state_monthly", "state_yearly", "upp_2010" or "upp_projection". character. |
Value
a dataframe.
Examples
## Not run: population(data = "cisp_monthly")
Spatial Data from Integrated Public Safety Area (AISP)
Description
This is the spatial data from the Integrated Public Safety Area (AISP) of the State of Rio de Janeiro.
Usage
spatial_aisp
Format
spatial_aisp
A spatial data frame
- aisp
Integrated Public Safety Areas (AISP) code
- risp
Integrated Public Safety Regions (RISP) code
- geometry
Spatial vector data of AISP
Source
https://www.ispdados.rj.gov.br/Arquivos/AISPshp.rar
Spatial Data from Integrated Public Safety Circumscriptions (CISP)
Description
This is the spatial data from the Integrated Public Safety Circumscriptions (CISP) of the State of Rio de Janeiro.
Usage
spatial_cisp
Format
spatial_cisp
A spatial data frame
- dp
id number
- aisp
Integrated Public Safety Areas (AISP) code
- geometry
Spatial vector data of CISP
Source
https://www.ispdados.rj.gov.br/Arquivos/CISPshp.rar
Access the information about spatial data
Description
Returns data about the spatial data in the package. If the data argument is "code_equivalence", it will show the equivalence between AISP, CISP and RISP codes, neighborhoods and cities. If the data argument is "area_km2", it returns a dataframe with the areas of AISP, CISP and RISP by square kilometers.
Usage
spatial_info(data)
Arguments
data |
it may be "code_equivalence" or "area_km2" |
Value
a dataframe
Examples
## Not run: spatial_info(data = "code_equivalence")
Spatial Data from Regions of the State of Rio de Janeiro
Description
This is the spatial data from the State of Rio de Janeiro.
Usage
spatial_regions_rj
Format
spatial_regions_rj
A spatial data frame
- id1
id number
- regiao
region name
- geometry
Spatial vector data of the regions
Source
https://www.ispdados.rj.gov.br/Arquivos/RegioesSHP.rar
Spatial Data from Integrated Public Safety Regions (RISP)
Description
This is the spatial data from the Integrated Public Safety Regions (RISP) of the State of Rio de Janeiro.
Usage
spatial_risp
Format
spatial_risp
A spatial data frame
- risp
risp number
- geometry
Spatial vector data of RISP
Source
https://www.ispdados.rj.gov.br/Arquivos/RISPshp.rar
Spatial data of Pacifying Police Units (UPP) - 2017 Limits
Description
This is the spatial data from the territorial limits of the Pacifying Police Units (UPPs) in the year of 2017.
Usage
spatial_upp
Format
spatial_upp
A spatial data frame
- nome
UPP name
- nomeabrev
UPP abbreviate name
- id_upp
UPP id number
- datacriaca
Creation date
- resolucaoc
resolution number
- geometry
Spatial vector data of UPPs limits in 2017
Source
https://www.ispdados.rj.gov.br/Arquivos/UPPshp.rar
Access data from Pacifying Police Units (UPPs)
Description
Returns data about Pacifying Police Units in the form of a dataframe.
Usage
upp_data(data)
Arguments
data |
selects the data: "stats", "dates" or "area_m2". character. |
Value
a dataframe.
Examples
## Not run: upp_data(data = "area_m2")
Access the public security statistics of the State of Rio de Janeiro by year
Description
Returns yearly data on police occurrences in the State of Rio de Janeiro in the form of a dataframe.
Usage
yearly_stats(by)
Arguments
by |
selects the spatial division of the data. It might be: "municipality" or "state". character. |
Details
Values per 100,000 inhabitants.
To see the dictionary of variables, use the function yearly_stats_dictionary().
Value
a dataframe
Examples
## Not run: yearly_stats(by = "state")
Access the dictionaries of public security statistics of the State of Rio de Janeiro by year
Description
Returns the data dictionary of the police occurrences in the State of Rio de Janeiro in the form of a dataframe.
Usage
yearly_stats_dictionary(by)
Arguments
by |
selects the spatial division of the dictionary. It might be: "municipality" or "state". character. |
Value
a dataframe
Examples
## Not run: yearly_stats_dictionary(by = "state")