s-news
[Top] [All Lists]

Loess span optimization: calculating AIC.

To: <s-news@lists.biostat.wustl.edu>
Subject: Loess span optimization: calculating AIC.
From: "Myers, Brent" <MyersDB@missouri.edu>
Date: Tue, 24 Feb 2004 11:08:26 -0600
Thread-index: AcP6+M2+BXzh461QQt6jpqI0d3JQxg==
Thread-topic: Loess span optimization: calculating AIC.

Good Day,

I am looking for a way to optimize selection of span for a loess model in S-Plus. Any options out there?

One option I am having trouble with…

The SAS documentation provides a macro that uses the unbiased AIC to optimize residual error and span.
Ref: Cohen, RA. Paper 273, An Introduction to PROC LOESS for Local Regression.

I am having difficulty porting this to S as I cannot identify all of the terms from the loess model.

Here is the theoretical model provided in the reference, it is to be calculated for each value of span.

AIC <- (n*(sigma.hat^2)) + (n*(((delta.1)/(delta.2*(n + traceL)))/((delta.1^2)/(delta.2 - 2))))

Terms required, the ones I am not sure of have question marks. Advide on identifying these terms would be appreciated.
n:  obvious
traceL:  loess.model$inference$trace.hat?
delta1:  loess.model$inference$one.delta
delta2:  loess.model$inference$two.delta
sigma.hat^2: loess.model$inference$s^2?



The macro calculation provided in the reference is not exactly like the one above, it is as follows and includes terms from the ODS output from SAS.

sigmaHat = rss/n
AIC = n*log(sigmaHat) + ((delta1/delta2)*(n+nul)/(lkdf-2))

Additional terms in the SAS macro by Cohen
rss(residual sum of squares): sum(loess.model$residual^2)?
nul: ???
lkdf(lookup degrees of freedom): ??? not same as enp

What are these extra terms that are not in the theoretical model?

D. Brenton Myers
Research Specialist
University of Missouri - Agronomy / USDA-ARS-ASEQ
158 Agriculture Engineering Building
Columbia, MO 65211
(573) 882-1146 wk
(573) 228-0929 cell
myersdb@missouri.edu
 

<Prev in Thread] Current Thread [Next in Thread>
  • Loess span optimization: calculating AIC., Myers, Brent <=