personal_finances_local() downloads and aggregates the data on federal candidates' personal financial disclosures. The function returns a data.frame where each observation corresponds to a candidate's property.
personal_finances_fed(year, uf = "all", br_archive = FALSE,
ascii = FALSE, encoding = "latin1", export = FALSE)Election year. For this function, only the years 2006, 2010, 2014 and 2018 are available.
Federation Unit acronym (character vector).
In the TSE's data repository, some results can be obtained for the whole country by loading a single
within a single file by setting this argument to TRUE (may not work in for some elections and, in
other, it recoverns only electoral data for presidential elections, absent in other files).
(logical). Should the text be transformed from Latin-1 to ASCII format?
Data original encoding (defaults to 'Latin-1'). This can be changed to avoid errors
when ascii = TRUE.
(logical). Should the downloaded data be saved in .dta and .sav in the current directory?
assets_candidate_local() returns a data.frame with the following variables:
DATA_GERACAO: Generation date of the file (when the data was collected).
HORA_GERACAO: Generation time of the file (when the data was collected), Brasilia Time.
ANO_ELEICAO: Election year.
DESCRICAO_ELEICAO: Description of the election.
SIGLA_UF: Units of the Federation's acronym in which occurred the election.
SQ_CANDIDATO: Candidate's ID ID attributed by TSE.
CD_TIPO_BEM_CANDIDATO: Code of the property.
DS_TIPO_BEM_CANDIDATO: Description of the property.
DETALHE_BEM: Addional details of the property.
VALOR_BEM: Value, in current Brazilian reais, of the property.
DATA_ULT_TOTALIZACAO: Date of the last totalization in that city and zone.
HORA_ULT_TOTALIZACAO: Time of the last totalization in that city and zone.
From 2018 on, some new variables are also available:
COD_TIPO_ELEICAO: Election type code.
NOME_TIPO_ELEICAO: Election type.
COD_ELEICAO: Election code.
DATA_ELEICAO: Election date.
ABRANGENCIA: Election scope.
NOME_UE: Electoral unit name.
NUMERO_ORDEM_CANDIDATO: Candidate's ordinal number.
DT_ULTIMA_ATUALIZACAO: Date when last updated.
HH_ULTIMA_ATUALIZACAO: Hour when last updated.
If export is set to TRUE, the downloaded data is saved as .dta and .sav
files in the current directory.
personal_finances_local for personal financial disclosures of running candidates in local elections.
# NOT RUN {
df <- personal_finances_fed(2006)
# }
Run the code above in your browser using DataLab