alvarobartt / investpy

Financial Data Extraction from Investing.com with Python
https://investpy.readthedocs.io/
MIT License
1.59k stars 375 forks source link

investpy.economic_calendar data before 2009 looks incorrect #304

Closed saumatony closed 3 years ago

saumatony commented 3 years ago

When running investpy.economic_calendar() with dates 2008 or earlier using January of the year to test:

countries = ['united states']
from_date = "01/01/2008"
to_date = "31/01/2008"
data = investpy.economic_calendar(countries=countries,time_filter="time_only",from_date=from_date, to_date=to_date)
for index, row in data.iterrows():
    print(row.date,row.event)

And then comparing the data when changing the dates to or later:

from_date = "01/01/2009"
to_date = "31/01/2009"

The results pre-2009 seem incorrect. Most of the data pre-2008 are appearing on Jan. 1st, but post-2009, the data is appearing in what seems to be the correct dates.

I am using v. 1.03

saumatony commented 3 years ago

Seems this is a problem with the data from investing.com itself.

Retracting my issue.

alvarobartt commented 3 years ago

Hi @saumatony, thanks for reporting this issue. Anyway, can you send me the URL of the Investing.com issue? If that's their issue I'll not be able to fix it, but anyway it's nice that you spotted this :+1: