1
$\begingroup$

I am building a data set of stock market data and was wondering how (what algorithm) to use (internally) to assign a key to each stock so that they key will remain the same always (tickers change and I would prefer to have a unique identifier for a company across time).

PS I have access to a survival free ticker list (including all ticker changes). I am looking for a simple algorithm to assign a permanent marker to each stock, even if ticker symbols change from time to time

PPS One may not assume that I have exhaustive history. My data starts at an arbitrary point in time and that starting date might change over time.

I understand there are many solutions out there (I will not add links to the websites of company that offer such "permanantId"). My question is which approach is the best (I have a strong preference for approaches that I can program myself, as opposed to calling an external API which might or might not be available in 10 years).

$\endgroup$
4
  • 2
    $\begingroup$ What behavior do you want when Company A and Company B merge into company C? $\endgroup$
    – JoshK
    Sep 11, 2019 at 16:28
  • $\begingroup$ @JoshK: that is an excellent question. As long as C is not traded/quoted before the merge date, I don't have a problem with it having a new symbol. What I want to avoid is company that when "SBC" became T (1/12/2005) I don't want to be in a situation where I have no price data for T prior to that date. $\endgroup$
    – user189035
    Sep 11, 2019 at 16:39
  • $\begingroup$ What about spin-offs? $\endgroup$
    – JoshK
    Sep 11, 2019 at 16:47
  • $\begingroup$ @JoshK: another excellent question. I suppose as long as the mother entity keeps its symbol (as in 3M Imation spin off, or HPQ's spin off of HPE), I would want the "perma-ticker" to also stay the same for the mother company. But my main point is I do not know enough about stocks to have an informed opinion on this. Answering my question also entails answering your sub questions. $\endgroup$
    – user189035
    Sep 11, 2019 at 17:25

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.