Home » date » 2008 » Dec » 15 »

dummy seasonal dummies

*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: Mon, 15 Dec 2008 11:29:28 -0700
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57.htm/, Retrieved Mon, 15 Dec 2008 19:31:46 +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/2008/Dec/15/t1229365906kltc46rog13uv57.htm/},
    year = {2008},
}
@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 = {2008},
    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:
 
Dataseries X:
» Textbox « » Textfile « » CSV «
101.02 0 100.67 0 100.47 0 100.38 0 100.33 0 100.34 0 100.37 0 100.39 0 100.21 0 100.21 0 100.22 0 100.28 0 100.25 0 100.25 0 100.21 0 100.16 0 100.18 0 100.1 1 99.96 1 99.88 1 99.88 1 99.86 1 99.84 1 99.8 1 99.82 1 99.81 1 99.92 1 100.03 1 99.99 1 100.02 1 100.01 1 100.13 1 100.33 1 100.13 1 99.96 1 100.05 1 99.83 1 99.8 1 100.01 1 100.1 1 100.13 1 100.16 1 100.41 1 101.34 1 101.65 1 101.85 1 102.07 1 102.12 1 102.14 1 102.21 1 102.28 1 102.19 1 102.33 1 102.54 1 102.44 1 102.78 1 102.9 1 103.08 1 102.77 1 102.65 1 102.71 1 103.29 1 102.86 1 103.45 1 103.72 1 103.65 1 103.83 1 104.45 1 105.14 1 105.07 1 105.31 1 105.19 1 105.3 1 105.02 1 105.17 1 105.28 1 105.45 1 105.38 1 105.8 1 105.96 1 105.08 1 105.11 1 105.61 1 105.5 1
 
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 time6 seconds
R Server'Sir Ronald Aylmer Fisher' @ 193.190.124.24


Multiple Linear Regression - Estimated Regression Equation
Suiker[t] = + 100.608354037267 + 1.88858695652174Dummy[t] -0.375916149068327M1[t] -0.378773291925467M2[t] -0.397344720496895M3[t] -0.301630434782611M4[t] -0.224487577639753M5[t] -0.485714285714286M6[t] -0.395714285714287M7[t] -0.094285714285716M8[t] -0.057142857142858M9[t] -0.0400000000000042M10[t] + 0.0271428571428547M11[t] + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)100.6083540372670.919321109.437700
Dummy1.888586956521740.5688013.32030.0014220.000711
M1-0.3759161490683271.105218-0.34010.7347640.367382
M2-0.3787732919254671.105218-0.34270.7328270.366413
M3-0.3973447204968951.105218-0.35950.7202750.360138
M4-0.3016304347826111.105218-0.27290.7857110.392855
M5-0.2244875776397531.105218-0.20310.8396250.419813
M6-0.4857142857142861.102227-0.44070.6607930.330397
M7-0.3957142857142871.102227-0.3590.7206510.360325
M8-0.0942857142857161.102227-0.08550.9320720.466036
M9-0.0571428571428581.102227-0.05180.9587990.4794
M10-0.04000000000000421.102227-0.03630.9711530.485576
M110.02714285714285471.1022270.02460.9804230.490211


Multiple Linear Regression - Regression Statistics
Multiple R0.386516860213904
R-squared0.149395283229615
Adjusted R-squared0.00563110574729608
F-TEST (value)1.03916904646144
F-TEST (DF numerator)12
F-TEST (DF denominator)71
p-value0.423929093603734
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation2.06207823139742
Sum Squared Residuals301.903830900621


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
1101.02100.2324378881990.78756211180124
2100.67100.2295807453420.440419254658389
3100.47100.2110093167700.258990683229812
4100.38100.3067236024840.0732763975155254
5100.33100.383866459627-0.0538664596273305
6100.34100.1226397515530.217360248447209
7100.37100.2126397515530.157360248447210
8100.39100.514068322981-0.124068322981365
9100.21100.551211180124-0.34121118012423
10100.21100.568354037267-0.358354037267083
11100.22100.63549689441-0.415496894409937
12100.28100.608354037267-0.32835403726708
13100.25100.2324378881990.0175621118012452
14100.25100.2295807453420.0204192546583849
15100.21100.211009316770-0.00100931677019287
16100.16100.306723602484-0.146723602484474
17100.18100.383866459627-0.203866459627322
18100.1102.011226708075-1.91122670807454
1999.96102.101226708075-2.14122670807454
2099.88102.402655279503-2.52265527950311
2199.88102.439798136646-2.55979813664597
2299.86102.456940993789-2.59694099378882
2399.84102.524083850932-2.68408385093167
2499.8102.496940993789-2.69694099378882
2599.82102.121024844720-2.3010248447205
2699.81102.118167701863-2.30816770186335
2799.92102.099596273292-2.17959627329192
28100.03102.195310559006-2.16531055900621
2999.99102.272453416149-2.28245341614907
30100.02102.011226708075-1.99122670807454
31100.01102.101226708075-2.09122670807453
32100.13102.402655279503-2.27265527950311
33100.33102.439798136646-2.10979813664596
34100.13102.456940993789-2.32694099378882
3599.96102.524083850932-2.56408385093168
36100.05102.496940993789-2.44694099378882
3799.83102.121024844720-2.29102484472050
3899.8102.118167701863-2.31816770186336
39100.01102.099596273292-2.08959627329192
40100.1102.195310559006-2.09531055900622
41100.13102.272453416149-2.14245341614907
42100.16102.011226708075-1.85122670807454
43100.41102.101226708075-1.69122670807454
44101.34102.402655279503-1.06265527950310
45101.65102.439798136646-0.789798136645957
46101.85102.456940993789-0.606940993788822
47102.07102.524083850932-0.454083850931682
48102.12102.496940993789-0.376940993788816
49102.14102.1210248447200.0189751552795068
50102.21102.1181677018630.0918322981366395
51102.28102.0995962732920.180403726708076
52102.19102.195310559006-0.00531055900621216
53102.33102.2724534161490.0575465838509306
54102.54102.0112267080750.528773291925472
55102.44102.1012267080750.338773291925465
56102.78102.4026552795030.377344720496897
57102.9102.4397981366460.460201863354043
58103.08102.4569409937890.623059006211182
59102.77102.5240838509320.245916149068321
60102.65102.4969409937890.153059006211185
61102.71102.1210248447200.5889751552795
62103.29102.1181677018631.17183229813665
63102.86102.0995962732920.760403726708074
64103.45102.1953105590061.25468944099379
65103.72102.2724534161491.44754658385093
66103.65102.0112267080751.63877329192547
67103.83102.1012267080751.72877329192547
68104.45102.4026552795032.0473447204969
69105.14102.4397981366462.70020186335404
70105.07102.4569409937892.61305900621118
71105.31102.5240838509322.78591614906833
72105.19102.4969409937892.69305900621118
73105.3102.1210248447203.17897515527950
74105.02102.1181677018632.90183229813664
75105.17102.0995962732923.07040372670808
76105.28102.1953105590063.08468944099379
77105.45102.2724534161493.17754658385094
78105.38102.0112267080753.36877329192546
79105.8102.1012267080753.69877329192546
80105.96102.4026552795033.55734472049689
81105.08102.4397981366462.64020186335404
82105.11102.4569409937892.65305900621118
83105.61102.5240838509323.08591614906832
84105.5102.4969409937893.00305900621118


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
160.006073369858257710.01214673971651540.993926630141742
170.0008402221991335330.001680444398267070.999159777800867
180.0001041325677051470.0002082651354102950.999895867432295
191.26654166229175e-052.53308332458351e-050.999987334583377
201.56166698075822e-063.12333396151645e-060.99999843833302
211.74593420198650e-073.49186840397301e-070.99999982540658
221.88535028623126e-083.77070057246251e-080.999999981146497
232.00985251341664e-094.01970502683328e-090.999999997990147
242.23930211638380e-104.47860423276761e-100.99999999977607
256.87829496969717e-111.37565899393943e-100.999999999931217
269.16440083811127e-121.83288016762225e-110.999999999990836
279.74142818817262e-131.94828563763452e-120.999999999999026
281.48103815054379e-132.96207630108759e-130.999999999999852
292.04876796536312e-144.09753593072625e-140.99999999999998
302.24363956995947e-154.48727913991893e-150.999999999999998
312.64072137605473e-165.28144275210947e-161
325.0087616319517e-171.00175232639034e-161
335.05509968002994e-171.01101993600599e-161
341.60610882935221e-173.21221765870442e-171
353.72125714147942e-187.44251428295884e-181
361.09277940449768e-182.18555880899537e-181
374.53360548298327e-199.06721096596654e-191
381.50059937679000e-193.00119875358001e-191
393.76622360725320e-207.53244721450641e-201
401.41111228206874e-202.82222456413749e-201
418.27291189943653e-211.65458237988731e-201
424.54569132588485e-219.0913826517697e-211
431.31630687039876e-202.63261374079753e-201
442.75925241125943e-165.51850482251886e-161
456.39042594885341e-131.27808518977068e-120.99999999999936
463.01241398047231e-106.02482796094462e-100.999999999698759
474.8491020854336e-089.6982041708672e-080.99999995150898
481.40661129056626e-062.81322258113252e-060.99999859338871
499.65055820512167e-061.93011164102433e-050.999990349441795
505.62989147498452e-050.0001125978294996900.99994370108525
510.000204925279588510.000409850559177020.999795074720412
520.000616715617479910.001233431234959820.99938328438252
530.001859763561870410.003719527123740820.99814023643813
540.004995128833031160.009990257666062310.995004871166969
550.01269240908424150.02538481816848310.987307590915758
560.03070303939055140.06140607878110280.969296960609449
570.05919221676911390.1183844335382280.940807783230886
580.099758853833610.199517707667220.90024114616639
590.2003552902685920.4007105805371850.799644709731408
600.3646505358950580.7293010717901170.635349464104942
610.5063644555957120.9872710888085760.493635544404288
620.5661350162205890.8677299675588220.433864983779411
630.6888802516700150.6222394966599690.311119748329985
640.756591516093740.4868169678125190.243408483906259
650.8101689861996160.3796620276007690.189831013800385
660.8607789894529880.2784420210940250.139221010547012
670.95122017388170.09755965223660150.0487798261183008
680.9970543993872780.005891201225444590.00294560061272230


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level390.735849056603774NOK
5% type I error level410.773584905660377NOK
10% type I error level430.811320754716981NOK
 
Charts produced by software:
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/103lhq1229365756.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/103lhq1229365756.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/16vch1229365756.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/16vch1229365756.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/284lg1229365756.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/284lg1229365756.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/3ie1o1229365756.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/3ie1o1229365756.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/4qybl1229365756.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/4qybl1229365756.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/5pkm71229365756.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/5pkm71229365756.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/6wikf1229365756.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/6wikf1229365756.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/7dgoi1229365756.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/7dgoi1229365756.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/8qi9l1229365756.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/8qi9l1229365756.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/95ufw1229365756.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/15/t1229365906kltc46rog13uv57/95ufw1229365756.ps (open in new window)


 
Parameters (Session):
par1 = 1 ; par2 = Include Monthly Dummies ; par3 = No Linear Trend ;
 
Parameters (R input):
par1 = 1 ; par2 = Include Monthly Dummies ; par3 = No 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