0
$\begingroup$

for a Quantitative project in Asset Management, I need to obtain for each year -on a long period (20 years) - the different historical constituents and their prices on a monthly basis for a given stock index (S&P 500 or CAC 40). How should I proceed? I have try with Bloomberg but it's not possible since I don't have full access. I do have access to Datastream but I only manage to have the historical prices on a monthly basis for the current constituents of the Index.

Many thanks in advance!

$\endgroup$
4
$\begingroup$

This is very difficult. S&P actually wants you to pay for weightings that currently exist - they started charging for the weightings 8 years ago or so - used to be free.

Historical constituents seem like something you will have to pay S&P for - especially with all the quant traders out there who would love such info.

Happy to delete this answer if someone proves me wrong, but I expect you have to pay for this.

$\endgroup$
2
  • 2
    $\begingroup$ If you have Factset at your academic institution this data may be included, Factset pays S&P for this data. Even Bloomberg has to pay S&P on a subscriber by subscriber basis or the subscriber will not get it. $\endgroup$ – noob2 Mar 17 '17 at 19:56
  • $\begingroup$ Many thanks for your answer! I will try to see if I can get the data from Factset and I will tell you if I manage to do so. $\endgroup$ – Paul Manigault Mar 18 '17 at 17:45
0
$\begingroup$

you can get S&P 500 historical constituents https://en.wikipedia.org/wiki/List_of_S%26P_500_companies get the add and remove date, and you can use python to pull the list from Yahoo systematically. Most yahoo data can go back as far as 1970.

import pandas_datareader.data as web
import pandas as pd
pd.set_option('display.max_columns', None)
data = web.get_data_yahoo('SPY', '01/01/1997', interval='m')
print(data)

for a school project, you can consider using SPY instead. SPY is very closely follows the S&P500 index.

There are a couple of things you might want to watch out for:

  1. Some of the underlying tickers might change names, due to different financial events.
  2. Some of the tickers' first add date might not be available.

the following is the output from the code.

                  High         Low        Open       Close        Volume   Adj Close
Date                                                                                
1997-01-01   79.687500   72.750000   74.375000   78.406250  4.362370e+07   50.724728
1997-02-01   82.000000   77.125000   78.718750   79.156250  3.002880e+07   51.209930
1997-03-01   81.796875   75.250000   78.750000   75.375000  3.751430e+07   48.763680
1997-04-01   80.687500   73.312500   75.250000   80.093750  5.767930e+07   52.014885
1997-05-01   85.562500   79.312500   80.218750   85.156250  3.747340e+07   55.302582
...                ...         ...         ...         ...           ...         ...
2021-02-01  394.170013  370.380005  373.720001  380.359985  1.307806e+09  379.118286
2021-03-01  398.119995  371.880005  385.589996  396.329987  2.401716e+09  395.036163
2021-04-01  420.720001  398.179993  398.399994  417.299988  1.462028e+09  417.299988
2021-05-01  422.820007  404.000000  419.429993  416.579987  8.737502e+08  416.579987
2021-05-14  417.489990  413.179993  413.209991  416.579987  8.220163e+07  416.579987

[294 rows x 6 columns]
                 
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.