hydrosquall / hydrosquall/tiingo-python

[Enhancement] Add new daily and IEX methods following the Tiingo API more closely

Open
#527 8 comments 0 reactions 0 assignees View on GitHub
enhancement feature
Dominant language
Python
Stars
319
Forks
58
PR merge metrics
No merged PRs in 30d

Description

### Description

Tiingo daily data and IEX intraday data are both being returned by the `get_dataframe` method but I propose they would be better off with their own methods. This would follow the Tiingo API more closely and users would be more aware of the source of the underlying data.

I suggest adding the method names `get_daily_data` and `get_iex_data`. The suffix `_data` is more appropriate in this case because if a `metric_name` is passed then the method returns a `pandas.Series` not a `pandas.DataFrame`.

I recommend only returning data in `csv` format from these new methods since this return type is so much faster than `json`. If `json` is included as a return type, test of equality between `csv` and `json` should be included. I've noticed that intraday `csv` response data coming from Tiingo contains a timezone offset while `json` response data does not contain a timezone offset. I would recommend using the same offset as the one returned by the `csv` response for simplicity. Again, the decision about which offset to use could be avoided by only allowing these methods to return `csv` data.

@hydrosquall Looking forward to your thoughts.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.