diff --git a/iqfeed/iqfeed.py b/iqfeed/iqfeed.py index c3e2219..32dfd60 100644 --- a/iqfeed/iqfeed.py +++ b/iqfeed/iqfeed.py @@ -42,11 +42,10 @@ def _get_daily_data(symbol: str, max_days: int) -> pd.DataFrame: data = data.replace(',\n','\n')[:-1] data = StringIO(data) - return pd.read_csv(data, index_col = False, - names=['Date', 'High', 'Low', 'Open', 'Close', 'Total Volume', 'Period Volume']) + return pd.read_csv(data, index_col = False, names = iqfeed_columns) def get_daily_data(symbol: str, start_date: datetime, end_date: datetime) -> pd.DataFrame: - max_days = (datetime.today() - start_date).days + max_days = (datetime.today() - start_date).days + 1 data = _get_daily_data(symbol, max_days) # Filter data between start_date and end_date