New get_estban() and tidy_estban():
download and read the monthly ESTBAN files (banking statistics by
municipality and institution: number of branches and COSIF account
balances of commercial and multiple banks and Caixa).
New get_branches() and tidy_branches():
download and read the monthly lists of branches (agências), service
posts (postos de atendimento, including cooperative posts since July
2016), electronic service posts (PAE) and branches of consortium
administrators, with the full 14-digit CNPJ, address, municipality and
opening date. Service posts have no CNPJ of their own and are identified
by id_instalacao (available from 2020).
get_institutions():
out_dir is not writable;
previously write errors were silently ignored and nothing was
saved.tidy_ifdata_reports(): fails gracefully when the input
is empty (e.g. when the IFdata API is unavailable and
get_ifdata_reports() returns no rows), returning an empty
tibble with an informative message. Input missing required columns now
gives a clear error.get_institutions(): the CONGLOMERADO file name (used
by Bacen after 2022) is now chosen per downloaded year instead of from
the whole years vector.
tidy_institutions(): fixed silent data loss and
harmonized columns across years.
201212COOPERATIVAS.xls had an “SCM” sheet first, so
only ~40 of ~1,250 cooperatives were imported; 2011 BANCOS/ADMCONSORCIO
have two position sheets).YYYYMM<INST>.ext) are read,
so the function no longer re-imports its own CSV output when
path_dir and out_dir are the same.?tidy_institutions). E-mail and website
columns are assigned by content, since Bacen’s headers for them are
inconsistent.data_inicio is now a Date in
every year, including files where Excel had swapped day and month
(201912, 202112).get_institutions(): fixed ADMCONSORCIO and CONGLOMERADO
bugs, and changed params. Now is possible to select years and months
individually.tidy_ifdata_reports(): removed function to import data
directly from .csv and .parquet. This will improve the speed to install
the package.Vignettes texts improved
Fixed error handle when website is not available at
get_normative_data()
tidy_ifdata_reports()get_ifdata_values() to
get_ifdata_reports()get_ifdata_reports()get_ifdata_registry(): Download institution registry
data from Bacen IFdata Cadastroget_ifdata_values(): Download data financial
information from IFdata of Brazilian Central Bank (Bacen)get_institutions(): Retrieve a list of financial
institutions regulated by the Central Bank of Brazil.tidy_institutions(): Tidy the institutions data for
easier analysis.download_normative_data() to
get_normative_data()download_normative_txt() to
get_normative_txt()download_balance_sheet() to
get_balance_sheet()treatment_balance_sheet() to
tidy_balance_sheet()Initial CRAN submission.
Functions for accessing Bacen data, such as:
get_normative_data(): Retrieve normative acts from the
Central Bank of Brazil.get_normative_txt(): Download normative act texts.get_balance_sheet(): Access the Central Bank’s balance
sheet data.tidy_balance_sheet(): Tidy the balance sheet data for
easier analysis.