The votings of the Brazilian Congress
Category: Open data
Organisation size: Big
Publication date: 5 Nov 2019
Credit: Gabriela Caesar, Antonio Lima, Thiago Reis, Clara Velasco, Rodrigo Cunha, Alexandre Mauro, Guilherme Gomes e Rogerio Banquieri
The project simplified the access to the results of 74 votings in the Brazilian Congress in 2019 and 61 votings in the past legislature. The database of the project has more than 37.000 rows of votings. This includes the Social Security Reform (2019), the impeachment of former president Dilma Rousseff (2016), the Labor Reform (2017) and bills about firearms legislation (2019). The data of the project refers to bills voted in the Brazilian Congress since 2015 and is still updated whenever a new voting happens.
Our tool displays these data in a very easy way to navigate and get pieces of information about each Brazilian congressman/congresswoman and about each bill voted in the past years. Each bill voted in the Congress has its own page on the project and presents the decisions and views of each congressman/congresswoman about that particular subject.
It also indicates if the congressman/congresswoman has voted with the majority of his/her party or not. Another advantage is that the tool has filters which allow the citizen to see the result by party, state or position.
The homepage of “G1”, the biggest news website in Brazil, related to the TV channel “TV Globo”, always has a link to the project when this happens. On the day that the tool was released, on the 11th of May 2019, the project has reached over 350.000 pageviews. The project has also been well received by political scientists, researchers and readers, who highlight the relevance of accessing this data more easily.
The main idea is to approach citizens and politicians, so they can see if their interests and promises are followed in the Congress. If the congressman/congresswoman was absent during the voting (or voted different of what the citizen expected), for example, the citizen can also send him/her a tweet or an email to question this behavior.
The programming language R was necessary to scrape, extract, clean, join and organize the data of the votings in the Brazilian Congress. The codes for downloading all the pictures of the deputies and senators were also written in R. Some of the data were also inside PDFs, and the team managed to get the content with OCR technology.
For updating the project, the leader of this project and data journalist Gabriela Caesar has coded some scripts in R, which get the data and automatize the processes, so all the content can be published in less than one minute after the voting. All the data team knows this language and is able to run these codes on RStudio.
After this step, all the data needs to be uploaded to Google Spreadsheet, because the system gets the new content with Google Spreadsheet API and PHP. With just one click the system updates the project, so a programmer’s assistance is no longer needed.
What was the hardest part of this project?
The hardest part of this project was to learn the programming language R (mainly the collection of R packages “tidyverse”) and be able to code scripts that scrape, extract, clean, join and organize the data of the voting in the Brazilian Congress. The data of the Senate and of the House of Representatives are published in different formats and different websites, and the scripts needed to run for both.
Since open data isn’t a reality in Brazil, it would be very tricky for each citizen to get the data on the official website of the Senate and of the House of Representatives. The results of the votings are kept hidden and have unfriendly formats for the general public, such as DBF and PDF. Our tool displays these data in a very easy way to navigate and get information about each Brazilian congressman/congresswoman and about each bill voted in the past years.
What can others learn from this project?
Others can learn from this project the fact that public data should always be open and accessible so that the general public can access and understand them in a simple way. The possibility to search for the name of a deputy or a senator makes it easier to monitor the Brazilian politicians’ activities. There is also the possibility to search for the bill.
If the bill was approved or declined by the Congress, media outlets can not only report the factual news but also display the data and show how each congressman/congresswoman has voted. Although the Brazilian citizens vote every four years for the Senate and for the House of Representatives, this doesn’t mean that the citizen should get information only during the election. There are ways (and this project is one of them) to keep in touch permanently and know their work better in the long term.
The project is also a very powerful tool to remind votings of past years and to help in the decision of the next voting for the Senate and for the House of Representatives. According to the results, the citizen can decide, for example, not to reelect a congressman/congresswoman.
The project is also very important because some issues related to politics are hard to understand and the project translates them in a simple, straightforward format. Politics should be reachable and understandable for the general public.
The reporters who cover the Congress and work in the Brazilian capital, Brasília, help the project with this part. For additional information, we call sources who work in the Congress.