Find top X S&P500 companies

Questions about MultiCharts and user contributed studies.
User avatar
signalworks
Posts: 65
Joined: 06 Oct 2013
Location: Germany.Solingen
Has thanked: 23 times
Been thanked: 2 times
Contact:

Find top X S&P500 companies

Postby signalworks » 01 Aug 2023

I would like to identify the top 10 S&P500 companies (by market capitalization) and trade them by script. Is it possible to select according to the market capitalization criterion? If yes, would it be possible to access it by code to trade a change in top 10 composition? (e.g. one share out, the new one in the portfolio). Thanks!

User avatar
TJ
Posts: 7743
Joined: 29 Aug 2006
Location: Global Citizen
Has thanked: 1033 times
Been thanked: 2222 times

Re: Find top X S&P500 companies

Postby TJ » 01 Aug 2023

Who is your dataprovider?
Do you know if your dataprovider supplies such a piece of information in a data field?

User avatar
signalworks
Posts: 65
Joined: 06 Oct 2013
Location: Germany.Solingen
Has thanked: 23 times
Been thanked: 2 times
Contact:

Re: Find top X S&P500 companies

Postby signalworks » 02 Aug 2023

Hello TJ,

I use the TWS coupled with MC. Only which field and where is this possibly in MC?
Thanks!

User avatar
signalworks
Posts: 65
Joined: 06 Oct 2013
Location: Germany.Solingen
Has thanked: 23 times
Been thanked: 2 times
Contact:

Re: Find top X S&P500 companies

Postby signalworks » 08 Aug 2023

Hello,
would anyone have any ideas about this?

User avatar
rrams
Posts: 128
Joined: 10 Feb 2011
Location: USA
Has thanked: 7 times
Been thanked: 70 times
Contact:

Re: Find top X S&P500 companies

Postby rrams » 08 Aug 2023

Hello,
Unfortunately, Interactive Brokers does not supply lists of stock symbols by exchange or index. You can download this information from several other sources such as https://www.barchart.com/stocks/indices ... erDir=desc.
S&P500-Top-Ten.txt
(837 Bytes) Downloaded 50 times
After you import the symbol list into QuoteManager, you could programmatically parse the csv file for changes to the market cap. It is not going to change often.


Return to “MultiCharts”