Total Market Cap of S&P 500

Is there a way to calculate this?

Based on the value of the index, you could do Close(0,$SP500) * 10000 which will give it to you in millions same way MktCap variable does.

Wouldn’t close(0,$SP500) multiplied by (current divisor/1,000,000) give me the total market cap in millions?

try a custom series. It comes up with $21530304 million:


Thanks David, that gives me a total market cap of 21,530,304 million, which is 21.5 trillion, which seems right…

The exact way would be to create a custom series. Use the S&P 500 for the universe and then use this rule:

UnivSum("True","MktCap")

If you named the series, for example, SPSum then you would reference it in a rule elsewhere with:

Close(0,GetSeries("SPSum"))

Thanks Paul. That seems to work. I’m calling it in a custom formula, which is called in a ranking system, which is used in a screen.

I can’t figure out why, but now the screen only holds positions every other rebalance period. Do you have any idea why? It wasn’t happening before I started using the custom series.

The screen is here: https://www.portfolio123.com/app/screen/summary/182544?st=1&mt=1