I want to do some analysis on daily prices of stocks in the S&P 500 over the last 10-20 years. Most datasets I have found only contain the stocks in the S&P 500 right now, but analyzing only that list is subject to survivorship bias.
I found a dataset for the list of components in the past. Now to try to get data for it:
At first, I tried using the Tradier API, but it returned no data for delisted stocks, of which there are a surprising number. Also, I found cases where data was missing, and a few cases of its data looking questionable, such as the open for one symbol jumping from around 34 to 0.005 and back over 3 days, another case of 2 digits to 4 digits and back, etc.
Then I found this article about finding a data provider.
So, I tried Tiingo's API. The data looks ok, and it appears to include delisted stocks. I very quickly run into the problem of ticker name changes and such. Searching around I think I found that ABC became COR, ABS to ACI, ABX... maybe GOLD? but I'm not sure. ACKH... I don't know. And yes, that's alphabetically and already running into that many changes and not past AC* yet.
Is there somewhere that has info that can help figure this out? It's going to take a long time to research all these (probably 100's) one at a time.
I found a dataset for the list of components in the past. Now to try to get data for it:
At first, I tried using the Tradier API, but it returned no data for delisted stocks, of which there are a surprising number. Also, I found cases where data was missing, and a few cases of its data looking questionable, such as the open for one symbol jumping from around 34 to 0.005 and back over 3 days, another case of 2 digits to 4 digits and back, etc.
Then I found this article about finding a data provider.
So, I tried Tiingo's API. The data looks ok, and it appears to include delisted stocks. I very quickly run into the problem of ticker name changes and such. Searching around I think I found that ABC became COR, ABS to ACI, ABX... maybe GOLD? but I'm not sure. ACKH... I don't know. And yes, that's alphabetically and already running into that many changes and not past AC* yet.
Is there somewhere that has info that can help figure this out? It's going to take a long time to research all these (probably 100's) one at a time.