Home » date » 2009 » Nov » 20 »

*The author of this computation has been verified*
R Software Module: /rwasp_multipleregression.wasp (opens new window with default values)
Title produced by software: Multiple Regression
Date of computation: Fri, 20 Nov 2009 06:54:09 -0700
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii.htm/, Retrieved Fri, 20 Nov 2009 14:57:57 +0100
 
BibTeX entries for LaTeX users:
@Manual{KEY,
    author = {{YOUR NAME}},
    publisher = {Office for Research Development and Education},
    title = {Statistical Computations at FreeStatistics.org, URL http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii.htm/},
    year = {2009},
}
@Manual{R,
    title = {R: A Language and Environment for Statistical Computing},
    author = {{R Development Core Team}},
    organization = {R Foundation for Statistical Computing},
    address = {Vienna, Austria},
    year = {2009},
    note = {{ISBN} 3-900051-07-0},
    url = {http://www.R-project.org},
}
 
Original text written by user:
 
IsPrivate?
No (this computation is public)
 
User-defined keywords:
Rob_WS7_3
 
Dataseries X:
» Textbox « » Textfile « » CSV «
106370 100.3 109375 101.9 116476 102.1 123297 103.2 114813 103.7 117925 106.2 126466 107.7 131235 109.9 120546 111.7 123791 114.9 129813 116 133463 118.3 122987 120.4 125418 126 130199 128.1 133016 130.1 121454 130.8 122044 133.6 128313 134.2 131556 135.5 120027 136.2 123001 139.1 130111 139 132524 139.6 123742 138.7 124931 140.9 133646 141.3 136557 141.8 127509 142 128945 144.5 137191 144.6 139716 145.5 129083 146.8 131604 149.5 139413 149.9 143125 150.1 133948 150.9 137116 152.8 144864 153.1 149277 154 138796 154.9 143258 156.9 150034 158.4 154708 159.7 144888 160.2 148762 163.2 156500 163.7 161088 164.4 152772 163.7 158011 165.5 163318 165.6 169969 166.8 162269 167.5 165765 170.6 170600 170.9 174681 172 166364 171.8 170240 173.9 176150 174 182056 173.8 172218 173.9 177856 176 182253 176.6 188090 178.2 176863 179.2 183273 181.3 187969 181.8 194650 182.9 183036 183.8 189516 186.3 193805 187.4 200499 189.2 188142 189.7 193732 191.9 1971 etc...
 
Output produced by software:

Enter (or paste) a matrix (table) containing all data (time) series. Every column represents a different variable and must be delimited by a space or Tab. Every row represents a period in time (or category) and must be delimited by hard returns. The easiest way to enter data is to copy and paste a block of spreadsheet cells. Please, do not use commas or spaces to seperate groups of digits!


Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time4 seconds
R Server'Gwilym Jenkins' @ 72.249.127.135


Multiple Linear Regression - Estimated Regression Equation
HFCE[t] = + 207810.550167275 -916.412977675751RPI[t] -12387.1281946683Q1[t] -7662.91380445677Q2[t] -3693.15077859989Q3[t] + 2256.38373280118t + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)207810.55016727515140.95500413.725100
RPI-916.412977675751142.774914-6.418600
Q1-12387.12819466831503.800975-8.237200
Q2-7662.913804456771498.259582-5.11452e-061e-06
Q3-3693.150778599891513.506414-2.44010.0167850.008392
t2256.38373280118172.29359213.096200


Multiple Linear Regression - Regression Statistics
Multiple R0.98769504249566
R-squared0.975541496970502
Adjusted R-squared0.974085633694937
F-TEST (value)670.07768747493
F-TEST (DF numerator)5
F-TEST (DF denominator)84
p-value0
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation5019.13495884401
Sum Squared Residuals2116104121.74756


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
1106370105763.584044531606.415955469496
2109375111277.921403262-1902.92140326173
3116476117320.785566385-844.785566384756
4123297122262.2658023431034.73419765748
5114813111673.3148516383139.68514836246
6117925116362.8805304611562.11946953911
7126466121214.4078226055251.59217739472
8131235125147.8337831206087.16621688032
9120546113367.5459614367178.45403856375
10123791117415.6225558876375.37744411349
11129813122633.7150391017179.28496089875
12133463126475.4997018486987.5002981519
13122987114420.2879868628566.71201313807
14125418116268.9734348909149.02656510961
15130199120570.6529404299628.34705957062
16133016124687.3614964798328.63850352105
17121454113915.1279502397538.87204976118
18122044118329.7697357593714.23026424060
19128313124006.0687078124306.93129218798
20131556128764.2663482352791.7336517654
21120027117992.0328019952034.96719800550
22123001122315.033289747685.966710252511
23130111128632.8213461731478.17865382688
24132524134032.508070969-1508.50807096875
25123742124726.535289010-984.535289009851
26124931129691.024861136-4760.02486113585
27133646135550.606428724-1904.60642872361
28136557141041.934451287-4484.93445128681
29127509130727.907393885-3218.90739388459
30128945135417.473072708-6472.47307270788
31137191141551.978533598-4360.97853359837
32139716146676.741365091-6960.74136509126
33129083135354.660032246-6271.6600322457
34131604139860.943115534-8256.94311553384
35139413145720.524683122-6307.5246831216
36143125151486.776598988-8361.77659898753
37133948140622.901754980-6674.90175497984
38137116145862.315220409-8746.31522040857
39144864151813.538085764-6949.53808576393
40149277156938.300917257-7661.30091725682
41138796145982.784775482-7186.78477548156
42143258151130.556943143-7872.55694314272
43150034155982.084235287-5948.08423528716
44154708160740.281875710-6032.28187570976
45144888150151.330925005-5263.33092500481
46148762154382.690114990-5620.69011499023
47156500160150.630384810-3650.63038481041
48161088165458.675811838-4370.67581183844
49152772155969.420434344-3197.4204343444
50158011161300.475197541-3289.47519754071
51163318167434.980658431-4116.9806584312
52169969172284.819596621-2315.81959662135
53162269161512.586050381756.413949618739
54165765165652.303942599112.696057400897
55170600171603.526807954-1003.52680795443
56174681176545.007043912-1864.00704391218
57166364166597.545177580-233.545177580242
58170240171653.676047474-1413.67604747384
59176150177788.181508364-1638.18150836433
60182056183920.998615301-1864.99861530054
61172218173698.612855666-1480.61285566590
62177856178754.743725559-898.74372555949
63182253184431.042697612-2178.04269761211
64188090188914.316444732-824.316444731976
65176863177867.159005189-1004.15900518914
66183273182923.289875083349.710124917284
67187969188691.230144903-722.230144902905
68194650193632.7103808611017.28961913935
69183036182677.194239085358.805760914604
70189516187366.7599179092149.24008209132
71193805192584.8524011231220.14759887658
72200499196884.8435527083614.15644729185
73188142186295.8926020031846.10739799680
74193732191260.3821741292471.6178258708
75197126196845.039848414280.960151585752
76205140201786.5200843723353.47991562801
77191751191197.569133667553.430866332951
78196700195062.3631325821637.63686741785
79199784199730.60782919153.3921708085906
80207360203755.6750874733604.32491252657
81196101192158.6698613253942.33013867486
82200824196115.1051580084708.89484199219
83205743201608.1215345254134.87846547471
84212489205083.3410062027405.6589937982
85200810193761.2596733567048.74032664374
86203683196892.9232901316790.07670986924
87207286201194.6027956706091.39720433025
88210910208885.3219646552024.67803534524
89194915202970.077200096-8055.07720009614
90217920208392.773261069527.22673893995


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
90.01336042205505580.02672084411011160.986639577944944
100.002584890055301170.005169780110602330.997415109944699
110.001077408554936540.002154817109873080.998922591445063
120.001075904946608910.002151809893217830.998924095053391
130.0007535473096564780.001507094619312960.999246452690344
140.0004069354686939780.0008138709373879560.999593064531306
150.0002007400050162540.0004014800100325080.999799259994984
160.0002828884395684160.0005657768791368320.999717111560432
170.003769155847630460.007538311695260920.99623084415237
180.04687239658915040.09374479317830070.95312760341085
190.1887962428680560.3775924857361120.811203757131944
200.4869445261601880.9738890523203760.513055473839812
210.7823894266431550.4352211467136890.217610573356845
220.8773258635035580.2453482729928850.122674136496442
230.9440848908387070.1118302183225860.0559151091612931
240.9758492672943880.04830146541122340.0241507327056117
250.9851139451569260.02977210968614720.0148860548430736
260.9837812816767980.03243743664640430.0162187183232021
270.987077457586390.02584508482721850.0129225424136092
280.984578877504540.03084224499091890.0154211224954594
290.9867557186478630.02648856270427380.0132442813521369
300.9801699199754760.03966016004904750.0198300800245237
310.9785723324617950.04285533507640930.0214276675382047
320.9687580235004760.06248395299904720.0312419764995236
330.957866898542040.08426620291592060.0421331014579603
340.9432829810507680.1134340378984640.0567170189492318
350.9245360427738840.1509279144522320.0754639572261158
360.90419959916230.1916008016754010.0958004008377004
370.8837851647513930.2324296704972140.116214835248607
380.8854720918373420.2290558163253160.114527908162658
390.868488578220090.263022843559820.13151142177991
400.8656585681463490.2686828637073020.134341431853651
410.8523286128748870.2953427742502260.147671387125113
420.8907703363459880.2184593273080250.109229663654012
430.886182444247510.2276351115049810.113817555752490
440.8987232488405860.2025535023188280.101276751159414
450.9028014315391640.1943971369216720.0971985684608359
460.9392059423792390.1215881152415220.0607940576207611
470.9456326655262990.1087346689474020.0543673344737011
480.9597038444545630.08059231109087380.0402961555454369
490.967668420159860.06466315968028070.0323315798401403
500.9831109489509650.03377810209807080.0168890510490354
510.983973552753160.03205289449367810.0160264472468391
520.9878614265909540.02427714681809150.0121385734090458
530.9935748523762970.01285029524740590.00642514762370294
540.9955516579132430.00889668417351440.0044483420867572
550.994834116374960.01033176725008150.00516588362504075
560.9946205993824280.01075880123514370.00537940061757184
570.993851770496730.01229645900653920.00614822950326962
580.9942138701179660.01157225976406840.00578612988203419
590.991982753702990.01603449259402120.0080172462970106
600.990681379595890.01863724080821880.00931862040410941
610.9861916453851020.02761670922979540.0138083546148977
620.9848109364327480.03037812713450390.0151890635672520
630.9784663081601330.04306738367973430.0215336918398671
640.9742013675516950.05159726489661010.0257986324483050
650.9627290395794070.07454192084118540.0372709604205927
660.9606348876716080.07873022465678420.0393651123283921
670.94475437772050.1104912445589990.0552456222794994
680.9284640438082750.1430719123834510.0715359561917254
690.8991121375802360.2017757248395280.100887862419764
700.8800620893396640.2398758213206720.119937910660336
710.8373408676271170.3253182647457660.162659132372883
720.7987524309842340.4024951380315320.201247569015766
730.7441095260342570.5117809479314860.255890473965743
740.6901728536962650.619654292607470.309827146303735
750.5998476996734990.8003046006530010.400152300326501
760.5207585625224240.9584828749551520.479241437477576
770.4224703663056360.8449407326112720.577529633694364
780.3699464444254910.7398928888509820.630053555574509
790.2908649932240980.5817299864481970.709135006775902
800.2000780679642170.4001561359284330.799921932035784
810.1312748641271970.2625497282543950.868725135872803


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level90.123287671232877NOK
5% type I error level310.424657534246575NOK
10% type I error level390.534246575342466NOK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/10ebvq1258725244.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/10ebvq1258725244.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/15pf31258725244.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/15pf31258725244.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/2icme1258725244.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/2icme1258725244.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/3y2421258725244.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/3y2421258725244.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/44b151258725244.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/44b151258725244.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/557vq1258725244.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/557vq1258725244.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/6u6k11258725244.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/6u6k11258725244.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/7xf6n1258725244.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/7xf6n1258725244.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/81aqo1258725244.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/81aqo1258725244.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/9vtnw1258725244.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Nov/20/t1258725465rmtllii0syw32ii/9vtnw1258725244.ps (open in new window)


 
Parameters (Session):
par1 = 1 ; par2 = Include Quarterly Dummies ; par3 = Linear Trend ;
 
Parameters (R input):
par1 = 1 ; par2 = Include Quarterly Dummies ; par3 = Linear Trend ;
 
R code (references can be found in the software module):
library(lattice)
library(lmtest)
n25 <- 25 #minimum number of obs. for Goldfeld-Quandt test
par1 <- as.numeric(par1)
x <- t(y)
k <- length(x[1,])
n <- length(x[,1])
x1 <- cbind(x[,par1], x[,1:k!=par1])
mycolnames <- c(colnames(x)[par1], colnames(x)[1:k!=par1])
colnames(x1) <- mycolnames #colnames(x)[par1]
x <- x1
if (par3 == 'First Differences'){
x2 <- array(0, dim=c(n-1,k), dimnames=list(1:(n-1), paste('(1-B)',colnames(x),sep='')))
for (i in 1:n-1) {
for (j in 1:k) {
x2[i,j] <- x[i+1,j] - x[i,j]
}
}
x <- x2
}
if (par2 == 'Include Monthly Dummies'){
x2 <- array(0, dim=c(n,11), dimnames=list(1:n, paste('M', seq(1:11), sep ='')))
for (i in 1:11){
x2[seq(i,n,12),i] <- 1
}
x <- cbind(x, x2)
}
if (par2 == 'Include Quarterly Dummies'){
x2 <- array(0, dim=c(n,3), dimnames=list(1:n, paste('Q', seq(1:3), sep ='')))
for (i in 1:3){
x2[seq(i,n,4),i] <- 1
}
x <- cbind(x, x2)
}
k <- length(x[1,])
if (par3 == 'Linear Trend'){
x <- cbind(x, c(1:n))
colnames(x)[k+1] <- 't'
}
x
k <- length(x[1,])
df <- as.data.frame(x)
(mylm <- lm(df))
(mysum <- summary(mylm))
if (n > n25) {
kp3 <- k + 3
nmkm3 <- n - k - 3
gqarr <- array(NA, dim=c(nmkm3-kp3+1,3))
numgqtests <- 0
numsignificant1 <- 0
numsignificant5 <- 0
numsignificant10 <- 0
for (mypoint in kp3:nmkm3) {
j <- 0
numgqtests <- numgqtests + 1
for (myalt in c('greater', 'two.sided', 'less')) {
j <- j + 1
gqarr[mypoint-kp3+1,j] <- gqtest(mylm, point=mypoint, alternative=myalt)$p.value
}
if (gqarr[mypoint-kp3+1,2] < 0.01) numsignificant1 <- numsignificant1 + 1
if (gqarr[mypoint-kp3+1,2] < 0.05) numsignificant5 <- numsignificant5 + 1
if (gqarr[mypoint-kp3+1,2] < 0.10) numsignificant10 <- numsignificant10 + 1
}
gqarr
}
bitmap(file='test0.png')
plot(x[,1], type='l', main='Actuals and Interpolation', ylab='value of Actuals and Interpolation (dots)', xlab='time or index')
points(x[,1]-mysum$resid)
grid()
dev.off()
bitmap(file='test1.png')
plot(mysum$resid, type='b', pch=19, main='Residuals', ylab='value of Residuals', xlab='time or index')
grid()
dev.off()
bitmap(file='test2.png')
hist(mysum$resid, main='Residual Histogram', xlab='values of Residuals')
grid()
dev.off()
bitmap(file='test3.png')
densityplot(~mysum$resid,col='black',main='Residual Density Plot', xlab='values of Residuals')
dev.off()
bitmap(file='test4.png')
qqnorm(mysum$resid, main='Residual Normal Q-Q Plot')
qqline(mysum$resid)
grid()
dev.off()
(myerror <- as.ts(mysum$resid))
bitmap(file='test5.png')
dum <- cbind(lag(myerror,k=1),myerror)
dum
dum1 <- dum[2:length(myerror),]
dum1
z <- as.data.frame(dum1)
z
plot(z,main=paste('Residual Lag plot, lowess, and regression line'), ylab='values of Residuals', xlab='lagged values of Residuals')
lines(lowess(z))
abline(lm(z))
grid()
dev.off()
bitmap(file='test6.png')
acf(mysum$resid, lag.max=length(mysum$resid)/2, main='Residual Autocorrelation Function')
grid()
dev.off()
bitmap(file='test7.png')
pacf(mysum$resid, lag.max=length(mysum$resid)/2, main='Residual Partial Autocorrelation Function')
grid()
dev.off()
bitmap(file='test8.png')
opar <- par(mfrow = c(2,2), oma = c(0, 0, 1.1, 0))
plot(mylm, las = 1, sub='Residual Diagnostics')
par(opar)
dev.off()
if (n > n25) {
bitmap(file='test9.png')
plot(kp3:nmkm3,gqarr[,2], main='Goldfeld-Quandt test',ylab='2-sided p-value',xlab='breakpoint')
grid()
dev.off()
}
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a, 'Multiple Linear Regression - Estimated Regression Equation', 1, TRUE)
a<-table.row.end(a)
myeq <- colnames(x)[1]
myeq <- paste(myeq, '[t] = ', sep='')
for (i in 1:k){
if (mysum$coefficients[i,1] > 0) myeq <- paste(myeq, '+', '')
myeq <- paste(myeq, mysum$coefficients[i,1], sep=' ')
if (rownames(mysum$coefficients)[i] != '(Intercept)') {
myeq <- paste(myeq, rownames(mysum$coefficients)[i], sep='')
if (rownames(mysum$coefficients)[i] != 't') myeq <- paste(myeq, '[t]', sep='')
}
}
myeq <- paste(myeq, ' + e[t]')
a<-table.row.start(a)
a<-table.element(a, myeq)
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable1.tab')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,hyperlink('http://www.xycoon.com/ols1.htm','Multiple Linear Regression - Ordinary Least Squares',''), 6, TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Variable',header=TRUE)
a<-table.element(a,'Parameter',header=TRUE)
a<-table.element(a,'S.D.',header=TRUE)
a<-table.element(a,'T-STAT<br />H0: parameter = 0',header=TRUE)
a<-table.element(a,'2-tail p-value',header=TRUE)
a<-table.element(a,'1-tail p-value',header=TRUE)
a<-table.row.end(a)
for (i in 1:k){
a<-table.row.start(a)
a<-table.element(a,rownames(mysum$coefficients)[i],header=TRUE)
a<-table.element(a,mysum$coefficients[i,1])
a<-table.element(a, round(mysum$coefficients[i,2],6))
a<-table.element(a, round(mysum$coefficients[i,3],4))
a<-table.element(a, round(mysum$coefficients[i,4],6))
a<-table.element(a, round(mysum$coefficients[i,4]/2,6))
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable2.tab')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a, 'Multiple Linear Regression - Regression Statistics', 2, TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'Multiple R',1,TRUE)
a<-table.element(a, sqrt(mysum$r.squared))
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'R-squared',1,TRUE)
a<-table.element(a, mysum$r.squared)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'Adjusted R-squared',1,TRUE)
a<-table.element(a, mysum$adj.r.squared)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'F-TEST (value)',1,TRUE)
a<-table.element(a, mysum$fstatistic[1])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'F-TEST (DF numerator)',1,TRUE)
a<-table.element(a, mysum$fstatistic[2])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'F-TEST (DF denominator)',1,TRUE)
a<-table.element(a, mysum$fstatistic[3])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'p-value',1,TRUE)
a<-table.element(a, 1-pf(mysum$fstatistic[1],mysum$fstatistic[2],mysum$fstatistic[3]))
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'Multiple Linear Regression - Residual Statistics', 2, TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'Residual Standard Deviation',1,TRUE)
a<-table.element(a, mysum$sigma)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'Sum Squared Residuals',1,TRUE)
a<-table.element(a, sum(myerror*myerror))
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable3.tab')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a, 'Multiple Linear Regression - Actuals, Interpolation, and Residuals', 4, TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'Time or Index', 1, TRUE)
a<-table.element(a, 'Actuals', 1, TRUE)
a<-table.element(a, 'Interpolation<br />Forecast', 1, TRUE)
a<-table.element(a, 'Residuals<br />Prediction Error', 1, TRUE)
a<-table.row.end(a)
for (i in 1:n) {
a<-table.row.start(a)
a<-table.element(a,i, 1, TRUE)
a<-table.element(a,x[i])
a<-table.element(a,x[i]-mysum$resid[i])
a<-table.element(a,mysum$resid[i])
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable4.tab')
if (n > n25) {
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Goldfeld-Quandt test for Heteroskedasticity',4,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'p-values',header=TRUE)
a<-table.element(a,'Alternative Hypothesis',3,header=TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'breakpoint index',header=TRUE)
a<-table.element(a,'greater',header=TRUE)
a<-table.element(a,'2-sided',header=TRUE)
a<-table.element(a,'less',header=TRUE)
a<-table.row.end(a)
for (mypoint in kp3:nmkm3) {
a<-table.row.start(a)
a<-table.element(a,mypoint,header=TRUE)
a<-table.element(a,gqarr[mypoint-kp3+1,1])
a<-table.element(a,gqarr[mypoint-kp3+1,2])
a<-table.element(a,gqarr[mypoint-kp3+1,3])
a<-table.row.end(a)
}
a<-table.end(a)
table.save(a,file='mytable5.tab')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity',4,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Description',header=TRUE)
a<-table.element(a,'# significant tests',header=TRUE)
a<-table.element(a,'% significant tests',header=TRUE)
a<-table.element(a,'OK/NOK',header=TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'1% type I error level',header=TRUE)
a<-table.element(a,numsignificant1)
a<-table.element(a,numsignificant1/numgqtests)
if (numsignificant1/numgqtests < 0.01) dum <- 'OK' else dum <- 'NOK'
a<-table.element(a,dum)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'5% type I error level',header=TRUE)
a<-table.element(a,numsignificant5)
a<-table.element(a,numsignificant5/numgqtests)
if (numsignificant5/numgqtests < 0.05) dum <- 'OK' else dum <- 'NOK'
a<-table.element(a,dum)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'10% type I error level',header=TRUE)
a<-table.element(a,numsignificant10)
a<-table.element(a,numsignificant10/numgqtests)
if (numsignificant10/numgqtests < 0.1) dum <- 'OK' else dum <- 'NOK'
a<-table.element(a,dum)
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable6.tab')
}
 





Copyright

Creative Commons License

This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 License.

Software written by Ed van Stee & Patrick Wessa


Disclaimer

Information provided on this web site is provided "AS IS" without warranty of any kind, either express or implied, including, without limitation, warranties of merchantability, fitness for a particular purpose, and noninfringement. We use reasonable efforts to include accurate and timely information and periodically update the information, and software without notice. However, we make no warranties or representations as to the accuracy or completeness of such information (or software), and we assume no liability or responsibility for errors or omissions in the content of this web site, or any software bugs in online applications. Your use of this web site is AT YOUR OWN RISK. Under no circumstances and under no legal theory shall we be liable to you or any other person for any direct, indirect, special, incidental, exemplary, or consequential damages arising from your access to, or use of, this web site.


Privacy Policy

We may request personal information to be submitted to our servers in order to be able to:

  • personalize online software applications according to your needs
  • enforce strict security rules with respect to the data that you upload (e.g. statistical data)
  • manage user sessions of online applications
  • alert you about important changes or upgrades in resources or applications

We NEVER allow other companies to directly offer registered users information about their products and services. Banner references and hyperlinks of third parties NEVER contain any personal data of the visitor.

We do NOT sell, nor transmit by any means, personal information, nor statistical data series uploaded by you to third parties.

We carefully protect your data from loss, misuse, alteration, and destruction. However, at any time, and under any circumstance you are solely responsible for managing your passwords, and keeping them secret.

We store a unique ANONYMOUS USER ID in the form of a small 'Cookie' on your computer. This allows us to track your progress when using this website which is necessary to create state-dependent features. The cookie is used for NO OTHER PURPOSE. At any time you may opt to disallow cookies from this website - this will not affect other features of this website.

We examine cookies that are used by third-parties (banner and online ads) very closely: abuse from third-parties automatically results in termination of the advertising contract without refund. We have very good reason to believe that the cookies that are produced by third parties (banner ads) do NOT cause any privacy or security risk.

FreeStatistics.org is safe. There is no need to download any software to use the applications and services contained in this website. Hence, your system's security is not compromised by their use, and your personal data - other than data you submit in the account application form, and the user-agent information that is transmitted by your browser - is never transmitted to our servers.

As a general rule, we do not log on-line behavior of individuals (other than normal logging of webserver 'hits'). However, in cases of abuse, hacking, unauthorized access, Denial of Service attacks, illegal copying, hotlinking, non-compliance with international webstandards (such as robots.txt), or any other harmful behavior, our system engineers are empowered to log, track, identify, publish, and ban misbehaving individuals - even if this leads to ban entire blocks of IP addresses, or disclosing user's identity.


FreeStatistics.org is powered by