Posts Tagged ‘ Uncategorized ’

Coherent population forecasting using R

July 24, 2014
By
Coherent population forecasting using R

This is an example of how to use the demography package in R for stochastic population forecasting with coherent components. It is based on the papers by Hyndman and Booth (IJF 2008) and Hyndman, Booth and Yasmeen (Demography 2013). I will use Australian data from 1950 to 2009 and forecast the next 50 years. In demography, “coherent” forecasts are where male and females (or other sub-groups) do not diverge over…

Read more »

Computing prediction ellipses from a covariance matrix

July 23, 2014
By
Computing prediction ellipses from a covariance matrix

In a previous blog post, I showed how to overlay a prediction ellipse on a scatter plot in SAS by using the ELLIPSE statement in PROC SGPLOT. The ELLIPSE statement draws the ellipse by using a standard technique that assumes the sample is bivariate normal. Today's article describes the technique […]

Read more »

Plotting the characteristic roots for ARIMA models

July 23, 2014
By
Plotting the characteristic roots for ARIMA models

When modelling data with ARIMA models, it is sometimes useful to plot the inverse characteristic roots. The following functions will compute and plot the inverse roots for any fitted ARIMA model (including seasonal models). # Compute AR roots arroots <- function(object) { if(class(object) != "Arima" & class(object) != "ar") stop("object must be of class Arima or ar") if(class(object) == "Arima") parvec <- object$model$phi else parvec <- object$ar if(length(parvec) > 0)…

Read more »

Add a prediction ellipse to a scatter plot in SAS

July 21, 2014
By
Add a prediction ellipse to a scatter plot in SAS

It is common in statistical graphics to overlay a prediction ellipse on a scatter plot. This article describes two easy ways to overlay prediction ellipses on a scatter plot by using SAS software. It also describes how to overlay multiple prediction ellipses for subpopulations. What is a prediction ellipse? A […]

Read more »

I am not an econometrician

July 21, 2014
By
I am not an econometrician

I am a statistician, but I have worked in a department of predominantly econometricians for the past 17 years. It is a little like an Australian visiting the United States. Initially, it seems that we talk the same language, do the same sorts of things, and have a very similar culture. But the longer you stay there, the more you realise there are differences that run deep and affect the…

Read more »

How to create and detect an empty matrix

July 18, 2014
By
How to create and detect an empty matrix

An empty matrix is a matrix that has zero rows and zero columns. At first "empty matrix" sounds like an oxymoron, but when programming in a matrix language such as SAS/IML, empty matrices arise surprisingly often. Sometimes empty matrices occur because of a typographical error in your program. If you […]

Read more »

Jan de Leeuw owns the Internet

July 16, 2014
By

One of the best things to happen on the Internet recently is that Jan de Leeuw has decided to own the Twitter/Facebook universe. If you do not already, you should be following him. Among his many accomplishments, he founded the … Continue reading →

Read more »

The SAS/IML File Exchange is open

July 16, 2014
By
The SAS/IML File Exchange is open

Have you written a SAS/IML program that you think is particularly clever? Are you the proud author of SAS/IML functions that extend the functionality of SAS software? You've worked hard to develop, debug, and test your program, so why not share it with others? There is now a central location […]

Read more »

Variations on rolling forecasts

July 15, 2014
By
Variations on rolling forecasts

Rolling forecasts are commonly used to compare time series models. Here are a few of the ways they can be computed using R. I will use ARIMA models as a vehicle of illustration, but the code can easily be adapted to other univariate time series models. One-step forecasts without re-estimation The simplest approach is to estimate the model on a single set of training data, and then compute one-step forecasts…

Read more »

SAS/IIF grants

July 14, 2014
By
SAS/IIF grants

Every year, the International Institute of Forecasters in conjunction with SAS offer some small grants to help promote research in forecasting. There are two $5000 grants per year for research on forecasting methodology and applications. This year, app...

Read more »


Subscribe

Email:

  Subscribe