-
-
Notifications
You must be signed in to change notification settings - Fork 224
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
expose tiingo split and dividend data #289
Comments
Thanks for this suggestion! I definitely think we should expose Tiingo's split and dividend data. Here are some thoughts, off the top of my head:
|
This is only true for OHLC outputs. There are I think it certainly makes sense to have consistency in outputs, but we should also not be afraid to provide additional valuable information where that makes sense. For example, in a continuous futures contract, it is very useful to know which contract you are using as the front month, and the volumes of both the front and near contracts. That type of data is meaningless in stock OHLC data. In adjusted stock data, the data becomes less useful as you go further back in time and the number of adjustments rises. This is why most people who use adjusted data for real analysis have some continuously back-adjusted model, so that when you look at the most recent data, it always matches currently observed prices. I think we can maintain consistency while still allowing for more advanced features and standards over time. |
If you consider the adjustment solution space as having 4 modes: unadjusted; splits adjusted; div adjusted; splits and div adjusted What im looking for is a solution model that supports switching between modes without a round trip to the server Also, while I see the adjustments mainly applied to listed equity OHLCV, as i describe in my use case above, I need the adjustment multipliers/values in order to apply them to other time series (transactions records). I agree with @braverock that adjustments are not a panacea.I i also think that people reasonably can do their own research and choose how/when they want to they want to apply them... When you use a data API, you need to understand the data One last point: there is upside to exposing the splits and divs as data points beyond just adjustments. Having these as data points allows searching/subsetting/visualization/analysis around these data points |
so, here are the solutions discussed so far:
I'd like to add the following additional ideas for consideration:
|
Proposal:
https://github.com/joshuaulrich/quantmod/search?q=adjusted |
Add adjusted close to output with unadjusted data, following the Yahoo pattern. This exposes both the adjusted and unadjusted data in a way that is compatible with other existing sources. It doesn't break any existing contract (both implied and specified) and doesn't require a radical re-design of the getSymbols() API. Closes #345. See #289.
Add adjusted close to output with unadjusted data, following the Yahoo pattern. This exposes both the adjusted and unadjusted data in a way that is compatible with other existing sources. It doesn't break any existing contract (both implied and specified) and doesn't require a radical re-design of the getSymbols() API. Closes #345. See #289.
While the |
I was actually thinking the exact same thing! |
something like:
(feel free to edit) |
the current tiingo
getSymbols
implementation only returns an OHLCV result. It does allow for an adjusted or un-adjusted result, but it does not expose thedivCash
orsplitFactor
columns. I'd like to expose this data so that I can use it in other processes. Specifically, i have some other data sources that only expose unadjusted prices. These sources need to be adjusted for splits (not divs), so i need access to the split factorThere are a few considerations in how to go about this:
getSymbols.yahoo
already includes an extra.Adjusted
column, in addition to the standard OHLCV columns, so it would not be unreasonable to just add these 2 columns to the end of the existing output. This would probably be the least invasive and simplest to implement, but would also create a go forward support issue that might interfere with a more radical API redesign approachAnother option would be to include a .Adjusted column to make it similar to the yahoo output, and to add parameters to the
getSymbols
call to control which adjustment to include, similar to howadjRatios
works. This would be a bit more complicated to implement, but could work across a number of sources. the biggest downside would be that it wouldn't allow use of split/divs/both in different situationsthis brings up the larger question of the framework design as a whole and how
getSplits()
,getDividends
,adjRatios
should work for sources other than yahoo. I certainly don't want to break existing functionality and design patterns, but it would seems silly to me to extend the existing 3 round trip call patterns to tiingo, when the data is already coming back as part of thegetSymbols
call.For reference, the alphavatange api does not expose div and split data directly, so it's not really a consideration here
any thoughts on the best way to go about this. I'm happy to do the lifting once a direction/approach is accepted
The text was updated successfully, but these errors were encountered: