Displaying 1 result from an estimated 1 matches for "regresultmatrix".
2011 Nov 22
0
Error in gls function in loop structure
...lm function, it works.)
The code looks like this:
=================================================
gls.lm <- function(Data, iv1, dv1)
{
gls.model <- gls(Data[ , dv1] ~ Data[ , iv1], correlation = corARMA(p=1),
method='ML',na.action=na.omit, data = Data)
print(summary(gls.model))
}
regResultMatrix <- gls.lm(DR, 'Period', 'Aircraft')
regResultMatrix <- gls.lm(DR, 'Period', 'Total.Employees')
==================================================
The "DR" is the data in excel file which includes three columns: Period,
Aircraft and Total.Employees.
An...