Wednesday, January 8, 2014

A Few Interesting Timeseries

Proud Economy 0012

Proud Economy 0012

econ307classnotes01

This time I'm just going to extract data for a few interesting timeseries that we need for our initial simple modeling and demonstrate extracting them live from the web.

library(quantmod)
seriesnames <- c("GDPMC1", "UNRATE", "CPIAUCSL", "FYFSD", "FYGFD", "GFDEGDQ188S", 
    "M1NS", "FEDFUNDS")
sapply(seriesnames, function(.m.) eval(parse(text = paste("setSymbolLookup(", 
    .m., "='FRED')"))))
getSymbols(seriesnames)
## [1] "GDPMC1"      "UNRATE"      "CPIAUCSL"    "FYFSD"       "FYGFD"      
## [6] "GFDEGDQ188S" "M1NS"        "FEDFUNDS"

Real Gross Domestic Product (GDPMC1)

So we have lost forever a half decade of wealth creation and still counting! Who's responsible?

FRED: Real Gross Domestic Product (GDPMC1)

chartSeries(GDPMC1, theme = "white", subset = "2000/", name = "Real Gross Domestic Product (GDPMC1)")

plot of chunk unnamed-chunk-4

Civilian Unemployment Rate (UNRATE)

What a waste!

FRED: Civilian Unemployment Rate (UNRATE)

chartSeries(UNRATE, theme = "white", subset = "2000/", name = "Civilian Unemployment Rate (UNRATE)")

plot of chunk unnamed-chunk-5

Consumer Price Index for All Urban Consumers: All Items (CPIAUCSL)

Here is a naturally occuring deflation experiment.

FRED: Consumer Price Index for All Urban Consumers: All Items (CPIAUCSL)

chartSeries(CPIAUCSL, theme = "white", subset = "2000/", name = "Consumer Price Index for All Urban Consumers: All Items (CPIAUCSL)")

plot of chunk unnamed-chunk-6

Federal Surplus or Deficit -

Deficit caused by your recession comes from the stimulus, the unemployment insurance paid, and the reduction in taxes collected. So making the recession worse by heavy government austerity won't turn that around.

FRED: Federal Surplus or Deficit [-] (FYFSD)

chartSeries(FYFSD, theme = "white", subset = "1970/", name = "Federal Surplus or Deficit [-] (FYFSD)")

plot of chunk unnamed-chunk-7

Gross Federal Debt (FYGFD)

The Federal Debt looks bad, but what about the public's huge wealth loss. If you don't fix that, we'll have another French Revolution.

FRED: Gross Federal Debt (FYGFD)

chartSeries(FYGFD, theme = "white", subset = "2000/", name = "Gross Federal Debt (FYGFD)")

plot of chunk unnamed-chunk-8

Federal Debt: Total Public Debt as Percent of Gross Domestic Product (GFDEGDQ188S)

FRED: Federal Debt: Total Public Debt as Percent of Gross Domestic Product (GFDEGDQ188S)

chartSeries(GFDEGDQ188S, theme = "white", subset = "2000/", name = "Federal Debt: Total Public Debt as Percent of Gross Domestic Product (GFDEGDQ188S)")

plot of chunk unnamed-chunk-9

M1 Money Stock (M1NS)

The Fed has had to pump the money supply, since Congress and the President aren't doing sufficient fiscal stimulus.

FRED: M1 Money Stock (M1NS)

chartSeries(M1NS, theme = "white", subset = "2000/", name = "M1 Money Stock (M1NS)")

plot of chunk unnamed-chunk-10

Effective Federal Funds Rate (FEDFUNDS)

Look at that zero lower bound. That's what Paul Krugman has been talking about for the past few years.

FRED: Effective Federal Funds Rate (FEDFUNDS)

chartSeries(FEDFUNDS, theme = "white", subset = "2000/", name = "Effective Federal Funds Rate (FEDFUNDS)")

plot of chunk unnamed-chunk-11

Gary Young (proudindiv)