JerBouma / FinanceToolkit

Transparent and Efficient Financial Analysis
https://www.jeroenbouma.com/projects/financetoolkit
MIT License
2.99k stars 361 forks source link

[BUG]: serious bug, missing Estimates dates #139

Closed arbitrage-technology closed 6 months ago

arbitrage-technology commented 7 months ago

doing toolkit.get_analyst_estimates() show missing dates!

for example 2023Q1, 2023Q3, 2023Q4: missing Q2

doing https://financialmodelingprep.com/api/v3/analyst-estimates/AMZN?period=quarter give all estimates.

i understood whats happening: its because some quaterly results, especially Q2, doesnt comes before 30 of June, which is the last date for a Q2, when second earning season comes in 01-07-2023, for pandas its a Q3!!!

cleverly, you do

financial_statement["date"] = pd.to_datetime(financial_statement["date"]) - pd.offsets.Day(1) for Statments

but not in for estimates which make the bug occuring

can u modify the code because i love this package

JerBouma commented 6 months ago

Hi! This is clear, I'll see if I can fix this somewhere this week. Please remind me if I don't 😉

JerBouma commented 6 months ago

Fyi, this has been resolved in v1.9.1