TradingView
xloexs
Mar 27, 2022 7:20 PM

Risk On Risk Off 

SPDR S&P 500 ETF TRUSTArca

Description

A helpful indicator for those who follow a systematic long-term investment approach.

What it shows:
It shows the 60 Day Cumulative Return of BND Vanguard Total Bond Market ETF against the 60 Day Cumulative Return of BIL SPDR Bloomberg Barclays 1-3 Month T-Bill ETF.

Why:
This Indicator will provide you a sense of where the economic environment is at, if the indicator shows that the 60 Day Cumulative return of BND is ABOVE BIL, it means that it's a good idea to go Risk ON in the stock market; On the other hand, if the inverse is true, it means that is a good idea to go Risk OFF in the stock market.

Example Uses:
Warren Buffet often advice Investors to just buy a S&P500 index tracking ETF like SPY consistently and you will likely to be making money in the long-term.

With this indicator you will be able to make the Buffet Strategy even simpler: when the indicator shows Risk ON, buy the SPY; when the indicator shows Risk OFF, consider hedges like IEF iShares 7-10 Year Treasury Bond ETF.AMEX:SPY
Comments
victro22
Appreciate your time in making this indicator! I have reviewed the code and it looks fine, though I have noticed some strange behaviour. It appears that there have been a number of events recently that the indicator was Risk On when it should've been Risk Off. Would appreciate if you could help me understand if I am missing something, or perhaps there is a bug.

For example, on 3/4/2022 (March 4) the indicator says it is Risk On. However on that day, BND closed at 81.86, and 60 trading days previously, on 12/7/2021, it closed at 85.26. This is a loss of -3.99%, where as in the same time period BIL was down -0.01%. The indicator should be showing Risk Off.

Currently (5/13/2022) the indicator is about to go back into Risk On territory, though by my calculation BND is down -6.49%. Perhaps I am not understanding it correctly, though I would appreciate if you could help me understand it, or see if there is something that isn't making sense in the code. Thank you very much for your time!
More