On-Line Course for Creating Database from FRED

This page walks through how to create a database that scrapes data from Federal Reserve Economic Database (FRED) that is published by the St. Louis Fed.  You can quickly scrape data and then compare, adjust, analyse and graph data in a flexible manner.  This page explains the steps of finding the FRED codes; using the Workbooks.open and text to columns to read a single series; reading multiple series using the INDEX function; summarising data using the INDIRECT function.

 

Introduction: Types of Data in Fred

1. Interest Rates: A few years ago you had to pay a lot for interest rate data from sources like Bloomberg. Now you can get very good historic data from the St. Louis Fed. This includes all sorts of interest rate maturities, swap rates, credit spreads and credit spreads from different countries. There are a couple of examples of downloading interest rates from the St. Louis Fed and the Federal Reserve Economic Database (FRED) below.

2. Exchange Rates: Exchange rate data is important for many reasons. For example, in acquiring stock price data, the data is generally expressed in terms of local prices; you probably want a common currency to compare the stock indicies. Finding historic exchange rates for countries such as the Philippines can be tricky and are not reported by the St. Louis Fed. To get the prices there are some alternatives one of which is http://www.x-rates.com/historical/?from=USD&amount=1&date=

3. Commodity Prices: Commodity prices can be very volatile, have mean reversion. Sources for acquiring data include the world bank and futures markets. The world bank website includes nice monthly data on many variables (except diesel prices, petrochemical prices and other prices that are from refined products). Electricity commodity prices are included on a separate page. The futures data is downloaded from:http://www.cmegroup.com/trading/energy/crude-oil/brent-crude-oil.html. The website for the world bank for the historic monthly data is below:
http://pubdocs.worldbank.org/en/561011486076393416/CMO-Historical-Data-Monthly.xlsx.

 

Finding FRED Codes

You can find FRED codes by going to the St. Louis Fed website.  You can look through data series in various different ways.  The problem is that you have to go one by one or use the tool provided by FRED (that I admit I do not use).

When you go to a time series, there is a code associated with the database.  You can find the code by selecting the time series and the making a graph.

 

Using the Workbooks.open and Text to Columns to Read a Single Series

 

Reading Multiple Series using the INDEX Function

 

Summarising Data using the INDIRECT Function