Friday, March 4, 2011

Death Spiral Warning Graph

In the death spiral scenario, rates go up while the currency goes down.  Here is the way to watch that.  I’m not saying that death spiral of US Dollar and interest rates occurs, but without significant action to restore confidence in fiscal and monetary policies, it is almost certain.  Fortunately free markets and a democracy might stop the spiral early, but it appears a mini-crisis is necessary to force action.

via StockCharts.com

And when we add this as the denominator or pricing mechanism for the S&P 500 (transformation requires removing natural $ pricing first), the chart looks like this.  The transitory fake improvement in stock prices since 2008 driven by aggressive monetary action is much clearer.  Anything through 14.3 on the green line is indicative of the first phase of this spiral.

 fed fred rates dollar sp500

And to throw a little R into this, let’s look at the rolling correlation of the SP500 to the 10y/US$ ratio.  The correlation magically increases in Summer 1998 with Long Term Capital Management and Russia default, and the Fed put became entrenched.

From TimelyPortfolio

 

 

R code:

require(quantmod)
require(PerformanceAnalytics)

#get currency rate and stock data from the FED FRED data series
getSymbols("DGS10",src="FRED") #load Fed 10y rate
getSymbols("DTWEXM",src="FRED") #load Fed Dollar
getSymbols("DTWEXO",src="FRED") #load Fed Dollar Other
getSymbols("SP500",src="FRED") #load Fed SP500

returns<-merge(monthlyReturn(to.monthly(DGS10/DTWEXM)),monthlyReturn(to.monthly(SP500)))

corSP10USD<-runCor(returns["1973::2011-02",1],returns["1973::2011-02",2],n=6)

chartSeries(corSP10USD,theme='white',name="S&P 500 Rolling 1y Correlation with US$ and US10y Rates")

2 comments:

  1. the code broke when calling runCor(). If you add:

    returns <- na.omit(returns)

    ahead of the call it works fine.

    ReplyDelete
  2. Hi milktrader, I put your suggestion to work. But, here is the result:

    First, your suggestion:


    require(quantmod)
    require(PerformanceAnalytics)

    #get currency rate and stock data from the FED FRED data series
    getSymbols("DGS10",src="FRED") #load Fed 10y rate
    getSymbols("DTWEXM",src="FRED") #load Fed Dollar
    getSymbols("DTWEXO",src="FRED") #load Fed Dollar Other
    getSymbols("SP500",src="FRED") #load Fed SP500

    returns<-merge(monthlyReturn(to.monthly(DGS10/DTWEXM)),monthlyReturn(to.monthly(SP500)))

    returns <- na.omit(returns)
    corSP10USD<-runCor(returns["1973::2011-02",1],returns["1973::2011-02",2],n=6)

    chartSeries(corSP10USD,theme='white',name="S&P 500 Rolling 1y Correlation with US$ and US10y Rates")


    Now, the error message:

    ntmod)
    > require(PerformanceAnalytics)
    >
    > #get currency rate and stock data from the FED FRED data series
    > getSymbols("DGS10",src="FRED") #load Fed 10y rate
    [1] "DGS10"
    > getSymbols("DTWEXM",src="FRED") #load Fed Dollar
    [1] "DTWEXM"
    > getSymbols("DTWEXO",src="FRED") #load Fed Dollar Other
    [1] "DTWEXO"
    > getSymbols("SP500",src="FRED") #load Fed SP500
    [1] "SP500"
    >
    > returns<-merge(monthlyReturn(to.monthly(DGS10/DTWEXM)),monthlyReturn(to.monthly(SP500)))
    1.#SNAN0, 94791600.000000
    Erro em merge.xts(e1, e2, all = FALSE, retclass = FALSE, retside = c(TRUE, :
    'NA' not allowed in 'index'

    Any suggestions? It would be great. Thanks for your time and attention.

    Claudio

    ReplyDelete