14.03.2014 Views

Modeling and Multivariate Methods - SAS

Modeling and Multivariate Methods - SAS

Modeling and Multivariate Methods - SAS

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

186 Fitting Generalized Linear Models Chapter 6<br />

Examples<br />

Second, goodness-of-fit statistics are presented. Analogous to lack-of-fit tests, they test for adequacy of the<br />

model. Low p-values for the ChiSquare goodness-of-fit statistics indicate that you may need to add<br />

higher-order terms to the model, add more covariates, change the distribution, or (in Poisson <strong>and</strong> binomial<br />

cases especially) consider adding an overdispersion parameter. AICc is also included <strong>and</strong> is the corrected<br />

Akaike’s Information Criterion, where<br />

AICc = -2loglikelihood + 2k( k+<br />

1 ))<br />

2k + ------------------------- n – k – 1<br />

<strong>and</strong> k is the number of estimated parameters in the model <strong>and</strong> n is the number of observations in the data<br />

set. This value may be compared with other models to determine the best-fitting model for the data. The<br />

model having the smallest value, as discussed in Akaike (1974), is usually the preferred model.<br />

The Effect Tests table shows joint tests that all the parameters for an individual effect are zero. If an effect<br />

has only one parameter, as with simple regressors, then the tests are no different from the tests in the<br />

Parameter Estimates table.<br />

The Parameter Estimates table shows the estimates of the parameters in the model <strong>and</strong> a test for the<br />

hypothesis that each parameter is zero. Simple continuous regressors have only one parameter. Models with<br />

complex classification effects have a parameter for each anticipated degree of freedom. Confidence limits are<br />

also displayed.<br />

Poisson Regression with Offset<br />

The sample data table Ship Damage.JMP is adapted from one found in McCullugh <strong>and</strong> Nelder (1983). It<br />

contains information on a certain type of damage caused by waves to the forward section of the hull. Hull<br />

construction engineers are interested in the risk of damage associated with three variables: ship Type, the<br />

year the ship was constructed (Yr Made) <strong>and</strong> the block of years the ship saw service (Yr Used).<br />

In this analysis we use the variable Service, the log of the aggregate months of service, as an offset variable.<br />

An offset variable is one that is treated like a regression covariate whose parameter is fixed to be 1.0.<br />

These are most often used to scale the modeling of the mean in Poisson regression situations with log link.<br />

In this example, we use log(months of service) since one would expect that the number of repairs be<br />

proportional to the number of months in service. To see how this works, assume the linear component of<br />

the GLM is called eta. Then with a log link function, the model of the mean with the offset included is:<br />

exp[Log(months of service) + eta] = [(months of service) * exp(eta)].<br />

To run this example, assign<br />

• Generalized Linear Model as the Personality<br />

• Poisson as the Distribution, which automatically selects the Log link function<br />

• N to Y<br />

• Service to Offset<br />

• Type, Yr Made, Yr Used as effects in the model<br />

• Overdispersion Tests <strong>and</strong> Intervals with a check mark

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!