Skip to content
Maurício Gedrat
← All work

Sentimento de notícias e retorno de açõesanálise de risco de carteiras na bolsa brasileira

Statistical research on the tone of economic news and stock returns on B3, Brazil's stock exchange

  • Data
  • Software
Year
Mar–Oct 2026
Context
Capstone project, Electronics Technician program — Fundação Liberato
Team
Maurício Gedrat, Leonardo Kohn
Award
2nd place, Computer Science — 41st MOSTRATEC-Liberato

Illustrative background photo: Tötös Ádám / Unsplash

Overview

We tested whether the tone of economic news anticipates stock returns on the Brazilian exchange, using Python for data collection, sentiment analysis and statistical tests.

Records

Maurício Gedrat and Leonardo Kohn at the awards ceremony, one of them showing the medal
Awards ceremony at the 41st MOSTRATEC-Liberato: 2nd place in Computer Science.
Maurício Gedrat and Leonardo Kohn at booth 101, in front of the project poster
Booth 101 at the fair.
MOSTRATEC finalist badges in front of the poster and the laptop running the project
Finalist badges, with the poster and the project running on the laptop.

The problem

Does news about a company move its stock, or does it only describe a move that already happened? The question sounds simple, but answering it means separating cause from coincidence in noisy time series.

The approach

  1. 01Collect economic news and daily B3 stock prices over the same period.
  2. 02Score the tone of each news item with sentiment analysis (natural language processing).
  3. 03Search news by the company's sector, not just its name — oil news affects Petrobras even when it isn't mentioned.
  4. 04Cross tone with returns at different lags, including the day before the news (D−1), to test whether the price had already moved.

How the system works

  1. 01

    News

    by company and sector

  2. 02

    Sentiment analysis

    tone of each item

  3. 03

    B3 prices

    daily returns

  4. 04

    Statistical tests

    correlation and lags

  5. 05

    D−1 backtest

    did the price move first?

Implementation

  • Python pipeline: collection, cleaning, sentiment scoring and alignment of news dates with trading days.
  • Interactive Streamlit dashboard to explore results by stock and by period.

Result

The project won 2nd place in the Computer Science category at the 41st MOSTRATEC-Liberato, an international science and technology fair, in October 2026.

Technologies

  • Python
  • NLP
  • Statistics
  • Streamlit
  • Git

Sources and links