Home » date » 2010 » Dec » 01 »

Paper

*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: Wed, 01 Dec 2010 15:17:25 +0000
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3.htm/, Retrieved Wed, 01 Dec 2010 16:48: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/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3.htm/},
    year = {2010},
}
@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 = {2010},
    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 «
1 162556 807 213118 6282154 1 29790 444 81767 4321023 1 87550 412 153198 4111912 0 84738 428 -26007 223193 1 54660 315 126942 1491348 1 42634 168 157214 1629616 0 40949 263 129352 1398893 1 45187 267 234817 1926517 1 37704 228 60448 983660 1 16275 129 47818 1443586 0 25830 104 245546 1073089 0 12679 122 48020 984885 1 18014 393 -1710 1405225 0 43556 190 32648 227132 1 24811 280 95350 929118 0 6575 63 151352 1071292 0 7123 102 288170 638830 1 21950 265 114337 856956 1 37597 234 37884 992426 0 17821 277 122844 444477 1 12988 73 82340 857217 1 22330 67 79801 711969 0 13326 103 165548 702380 0 16189 290 116384 358589 0 7146 83 134028 297978 0 15824 56 63838 585715 1 27664 236 74996 657954 0 11920 73 31080 209458 0 8568 34 32168 786690 0 14416 139 49857 439798 1 3369 26 87161 688779 1 11819 70 106113 574339 1 6984 40 80570 741409 1 4519 42 102129 597793 0 2220 12 301670 644190 0 18562 211 102313 377934 0 10327 74 88577 640273 1 5336 80 112477 697458 1 2365 83 191778 550608 0 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 time9 seconds
R Server'George Udny Yule' @ 72.249.76.132
R Framework
error message
The field 'Names of X columns' contains a hard return which cannot be interpreted.
Please, resubmit your request without hard returns in the 'Names of X columns'.


Multiple Linear Regression - Estimated Regression Equation
Wealth [t] = -119201.506007196 + 194798.386004110Group[t] + 19.0472970135833Costs[t] + 1974.32364909872Orders[t] + 2.42321936149088Dividends[t] + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)-119201.506007196114732.051052-1.0390.3014630.150731
Group194798.38600411097817.1770561.99150.0493030.024651
Costs19.04729701358334.5040534.22895.4e-052.7e-05
Orders1974.32364909872800.9745942.46490.0155010.007751
Dividends2.423219361490880.9023292.68550.0085470.004274


Multiple Linear Regression - Regression Statistics
Multiple R0.831262431338051
R-squared0.690997229754048
Adjusted R-squared0.677986586796324
F-TEST (value)53.1101523575212
F-TEST (DF numerator)4
F-TEST (DF denominator)95
p-value0
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation474667.31148489
Sum Squared Residuals21404360376267.9


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
162821545281560.142041841000593.85795816
243210231717754.935762422603268.06423758
341119122927841.436706491184070.56329351
42231932276818.20420978-2053625.20420978
514913482046242.39641185-554894.396411852
616296161600309.7226200429306.2773799605
713988931493461.64996256-94568.6499625583
819265172032444.60526627-105927.605266267
99836601390380.72255497-406720.722554969
101443586756152.893054489687433.106945511
1110730891173131.65669657-100042.656696568
12984885479529.651756862505355.348243138
1314052251190480.37738725214744.622612750
142271321164657.32175915-937525.32175915
159291181332043.95406673-402925.954066727
161071292497175.9585507574116.0414493
17638830916152.526229454-277322.526229454
188569561293944.44859101-436988.448591012
199924261345511.08199643-353085.081996428
204444771064805.98411520-620328.984115202
21857217666636.682218701190580.317781299
22711969826578.035066179-114609.035066179
23702380739137.228709075-36757.2287090749
243585891043733.00575209-685144.005752086
25297978505558.585908963-207580.585908963
26585715447458.523884129138256.476115871
276579541250193.44500235-592239.445002352
28209458327281.558534059-117823.558534059
29786690189072.85929498597617.14070502
30439798550629.762671193-110831.762671193
31688779402309.861279151286469.138720849
32574339696054.614943248-121715.614943248
33741409482834.93225905258574.06774095
34597793492074.178633146105718.821366854
35644190677787.961933097-33597.9619330973
36377934898863.553650982-520929.553650982
37640273438241.381668161202031.618331839
38697458607735.59291170389722.4070882974
39550608749232.763017231-198624.763017231
40207393410320.941497423-202927.941497423
41301607756963.156532259-455356.156532259
42345783486366.09975174-140583.09975174
43501749370026.949269874131722.050730126
44379983470151.597662202-90168.5976622022
45387475213535.434707864173939.565292136
46377305441884.795152372-64579.7951523716
47370837775751.5230066-404914.5230066
48430866844387.670694154-413521.670694154
49469107384098.97285706985008.0271429313
50194493190391.0188608624101.9811391377
51530670575410.940639718-44740.9406397179
52518365749701.796815861-231336.796815861
53491303863546.543166312-372243.543166312
54527021575892.346863288-48871.3468632883
55233773768887.623247804-535114.623247804
56405972226889.832442529179082.167557471
5765292586042.7999453715566882.200054629
58446211288459.540150379157751.459849621
59341340247048.44781465894291.5521853418
60387699632903.942778169-245204.942778169
61493408495133.867642223-1725.86764222317
62146494119264.25180201627229.748197984
63414462413826.809453132635.190546868282
64364304571370.269568106-207066.269568106
65355178181374.627612576173803.372387424
66357760848886.148622456-491126.148622456
67261216122949.285535447138266.714464553
68397144444918.179265144-47774.1792651437
69374943369770.301125595172.69887440978
70424898563263.063074457-138365.063074457
71202055296564.343358659-94509.3433586588
72378525147925.966724330230599.033275670
73310768236162.30519064974605.6948093514
74325738101244.556456021224493.443543979
75394510273618.650577384120891.349422616
76247060336799.388704870-89739.3887048705
77368078235437.784073997132640.215926003
7823676197298.9457546389139462.054245361
79312378176172.796869287136205.203130713
80339836399571.030165814-59735.0301658135
81347385112111.912797848235273.087202152
82426280513393.633240494-87113.6332404941
83352850299393.82448270953456.1755172911
8430188121937.9156974166279943.084302583
85377516169128.868303416208387.131696584
86357312473933.291299756-116621.291299756
87458343366325.74063303592017.2593669652
88354228168668.126639013185559.873360987
89308636267965.17398166140670.826018339
90386212169666.447400162216545.552599838
91393343221528.819894352171814.180105648
92378509411632.459579599-33123.4595795993
93452469212065.851158408240403.148841592
94364839564819.026377326-199980.026377326
9535864992610.9079413748266038.092058625
96376641339007.77871811437633.2212818855
97429112177559.943374048251552.056625952
98330546316036.10592116914509.8940788306
99403560282505.680572930121054.319427070
100317892297138.74947631320753.2505236870


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
80.9999999999984063.18829107649308e-121.59414553824654e-12
90.9999999999927731.44531628744812e-117.22658143724062e-12
100.9999999999999931.42280010290397e-147.11400051451986e-15
110.9999999999999984.73600824587067e-152.36800412293533e-15
1214.46591172946131e-182.23295586473066e-18
1314.75278995391256e-242.37639497695628e-24
1411.07046487876317e-265.35232439381584e-27
1511.13561589046310e-285.67807945231552e-29
1614.88833491812956e-322.44416745906478e-32
1711.15931893957694e-325.79659469788472e-33
1814.43186281324715e-342.21593140662358e-34
1911.77715569973115e-338.88577849865577e-34
2011.90818990315379e-339.54094951576893e-34
2117.04953882844098e-343.52476941422049e-34
2215.05774018357252e-332.52887009178626e-33
2311.50671116021554e-327.53355580107772e-33
2412.86569141579555e-321.43284570789778e-32
2519.71127629275803e-324.85563814637901e-32
2611.10794916353421e-315.53974581767107e-32
2711.86499998453973e-319.32499992269863e-32
2811.10219374879210e-315.51096874396051e-32
2915.24054633751549e-342.62027316875775e-34
3013.52396343131097e-331.76198171565549e-33
3111.60792332344183e-338.03961661720916e-34
3218.84243565808334e-334.42121782904167e-33
3311.01690004274575e-335.08450021372874e-34
3411.57270145863342e-337.8635072931671e-34
3517.8664852563727e-333.93324262818635e-33
3613.23813939561939e-321.61906969780970e-32
3711.22886568270673e-326.14432841353364e-33
3818.36090404001015e-344.18045202000507e-34
3911.84208215700095e-339.21041078500475e-34
4013.68835128190077e-331.84417564095038e-33
4119.32589778354368e-334.66294889177184e-33
4214.38853391827711e-322.19426695913856e-32
4311.18274732226267e-315.91373661131333e-32
4418.48169497479217e-314.24084748739608e-31
4514.83121260843323e-302.41560630421661e-30
4613.51285425746296e-291.75642712873148e-29
4718.41041548812615e-294.20520774406307e-29
4813.98887252464113e-281.99443626232057e-28
4912.18476482234208e-271.09238241117104e-27
5012.99714072711949e-271.49857036355974e-27
5114.40048823674942e-272.20024411837471e-27
5215.56611720948336e-272.78305860474168e-27
5312.92882427012348e-261.46441213506174e-26
5411.16603787556264e-265.83018937781318e-27
5512.09424360969568e-261.04712180484784e-26
5618.77088089707743e-264.38544044853872e-26
5711.23458063407922e-286.17290317039612e-29
5815.90685703280281e-282.95342851640141e-28
5915.42462777028401e-272.71231388514201e-27
6014.84999680777e-262.424998403885e-26
6118.77362197767456e-264.38681098883728e-26
6218.07108600144844e-274.03554300072422e-27
6314.90433627602499e-262.45216813801250e-26
6415.17198941052967e-252.58599470526483e-25
6514.95125313348991e-242.47562656674495e-24
6611.39470932140279e-246.97354660701397e-25
6715.91570800418672e-242.95785400209336e-24
6814.65776116717963e-232.32888058358981e-23
6913.14225547199888e-221.57112773599944e-22
7013.30844597423774e-211.65422298711887e-21
7112.15631696843964e-211.07815848421982e-21
7212.19457596550924e-201.09728798275462e-20
7319.68169476294826e-204.84084738147413e-20
7411.12144845385625e-185.60724226928127e-19
7511.28950710990591e-176.44753554952953e-18
7612.91054221552848e-171.45527110776424e-17
7713.43368413217738e-161.71684206608869e-16
7813.28279801628071e-161.64139900814035e-16
7918.65389475597113e-164.32694737798556e-16
800.9999999999999941.09763365538639e-145.48816827693194e-15
810.999999999999931.39590094605682e-136.9795047302841e-14
820.9999999999993141.37186440135981e-126.85932200679905e-13
830.9999999999966976.60545958676148e-123.30272979338074e-12
840.9999999999712625.74762844046524e-112.87381422023262e-11
850.999999999620857.58300593938408e-103.79150296969204e-10
860.9999999957326338.53473329433435e-094.26736664716717e-09
870.9999999516227329.67545350931405e-084.83772675465702e-08
880.9999995145420489.70915904511296e-074.85457952255648e-07
890.9999999245408241.50918351609489e-077.54591758047445e-08
900.999998509568292.98086342167626e-061.49043171083813e-06
910.9999797376134824.05247730350019e-052.02623865175010e-05
920.9996236191022230.0007527617955531080.000376380897776554


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level851NOK
5% type I error level851NOK
10% type I error level851NOK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/10mfz61291216634.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/10mfz61291216634.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/1fw2c1291216634.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/1fw2c1291216634.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/2fw2c1291216634.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/2fw2c1291216634.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/385kx1291216634.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/385kx1291216634.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/485kx1291216634.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/485kx1291216634.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/585kx1291216634.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/585kx1291216634.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/6ie101291216634.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/6ie101291216634.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/7t50l1291216634.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/7t50l1291216634.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/8t50l1291216634.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/8t50l1291216634.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/9t50l1291216634.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/01/t1291218515d4u5j0dyw3bbqe3/9t50l1291216634.ps (open in new window)


 
Parameters (Session):
par1 = 5 ; par2 = Do not include Seasonal Dummies ; par3 = No Linear Trend ;
 
Parameters (R input):
par1 = 5 ; par2 = Do not include Seasonal 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