Macro Factors

Hi all,

Lately, I've been looking into Macro Factors. As a starting point, I have tried to come up with factors based on the high yield spread and the 1 year US treasury yield.

My idea was that when the high yield spread is high and rising, I would want to invest more in stocks that have done well in those enviroments and hence have a positive beta to changes in the high yield spread.

The same for when the high yield spread is high and falling. I would then want to invest more in stocks that have low (negative) beta to changes in the high yield spread.

In other scenarios I would be indifferent.

I had similar thoughts in the case of treasuries.

To implement this, I made the following ranking system:
https://www.portfolio123.com/app/ranking-system/511404

I noticed that when I take a lookback that is too far, the linear regression outsputs will more often become NA. More importantly, I found that while in the US these factors worked decently, I didn't get the same output in Europe.

See below for the ranking output for the Easy to Trade Universe.


Have others tried similar ideas?

Best,

Victor :slight_smile:

1 Like

I have tried something similar, but it mainly creates higher turnover for me.

Something I really would like to have is macro as base to create dynamic weight for the factors.

Like the higher volatility in SPY, the less Beta weight. With use of a volatility limit condition to create a true or false condition, it would create very high turnover at times. If it would be dynamic, it think that would be less of a problem.

I have a few macro flags that I use just to get a feel of the economy. I generally put these in functions and then add it up for a total score among some other factors. In one of my accounts I will adjust my cash positioning up or down depending on the score, or I will put some money into a tail risk ETF with out of the money puts (like $CAOS) for a hedging

Total Inventories
eval(CLOSE(0,##INVTOT) > EMA(25,0,##INVTOT),0,1)

Retail Sales (Intuitively think this is a good leading indicator. If people see dark clouds on the horizon at their job they curb spending)

eval(CLOSE(0,##SALESRETFD) > SMA(50,0,##SALESRETFD),0,1)

Industrial Production
eval(CLOSE(0,##INDPRO) > SMA(30,0,##INDPRO),0,1)

Unemployment
Eval(EMA(2,0,#UNEMP)<=EMA(2,3,#UNEMP),0,1)

2 Likes

Hi,

This is really an interesting approch. I’m new to P123. Does any one know whether I can regress certain macro factors against some common ETFs like SPY, TLT, VNQ to discover exposure and adjust tilt? Macro factors I’d be curious to regress would be fed funds rate, long bond yields, inflation expectations, pmi etc.

How might I implement this ?

Does P123 do any MVA ?

Thx.

You might could use some simple moving averages of bond ETFs to try to get a handle on credit yield spreads. HYG as a stand in for High yield and IEI as as proxy for middle of the treasury yield curve.

Just doing a quick a dirty formula after running the idea by Claude…

Eval(EMA(20,0,GetSeries("HYG"))/EMA(20,0,GetSeries("IEI"))>SMA(120,0,GetSeries("HYG"))/SMA(120,0,GetSeries("IEI")),Ticker("SPY"),Ticker("SHY"))

This would have cost you 2% annual return on pure buy and hold SPY, but cut max drawdown nearly in half and kept you out of the depths of the GFC, 2011 Debt Ceiling, March 2020 Covid and 2025 Liberation Day panics.

1 Like

recessionalert.com is excellent for macro plus market timing.

2 Likes