Home » date » 2010 » Dec » 15 »

MRbel20

*Unverified author*
R Software Module: /rwasp_multipleregression.wasp (opens new window with default values)
Title produced by software: Multiple Regression
Date of computation: Wed, 15 Dec 2010 15:14:45 +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/15/t1292426070sp2yban07lgjyi9.htm/, Retrieved Wed, 15 Dec 2010 16:14:40 +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/15/t1292426070sp2yban07lgjyi9.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 «
3.32 523 -3 2065.81 10457 28.37 111.22 3.30 519 -3 1940.49 10368 27.34 111.09 3.30 509 -4 2042.00 10244 24.46 111 3.09 512 -8 1995.37 10511 27.46 111.06 2.79 519 -9 1946.81 10812 30.23 111.55 2.76 517 -13 1765.90 10738 32.33 112.32 2.75 510 -18 1635.25 10171 29.87 112.64 2.56 509 -11 1833.42 9721 24.87 112.36 2.56 501 -9 1910.43 9897 25.48 112.04 2.21 507 -10 1959.67 9828 27.28 112.37 2.08 569 -13 1969.60 9924 28.24 112.59 2.10 580 -11 2061.41 10371 29.58 112.89 2.02 578 -5 2093.48 10846 26.95 113.22 2.01 565 -15 2120.88 10413 29.08 112.85 1.97 547 -6 2174.56 10709 28.76 113.06 2.06 555 -6 2196.72 10662 29.59 112.99 2.02 562 -3 2350.44 10570 30.70 113.32 2.03 561 -1 2440.25 10297 30.52 113.74 2.01 555 -3 2408.64 10635 32.67 113.91 2.08 544 -4 2472.81 10872 33.19 114.52 2.02 537 -6 2407.60 10296 37.13 114.96 2.03 543 0 2454.62 10383 35.54 114.91 2.07 594 -4 2448.05 10431 37.75 115.3 2.04 611 -2 2497.84 10574 41.84 115.44 2.05 613 -2 2645.64 10653 42.94 115.52 2.11 611 -6 2756.76 10805 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 time8 seconds
R Server'George Udny Yule' @ 72.249.76.132


Multiple Linear Regression - Estimated Regression Equation
BEL20[t] = -11758.0439129435 + 367.515883266901Eonia[t] + 6.35912382598827Werkloosheid[t] + 68.3919666471223Consumentenvertrouwen[t] -0.0455205559904635Goudprijs[t] + 2.57032745934426Olieprijs[t] + 94.2348952432762CPI[t] + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)-11758.04391294352991.788773-3.93010.0001648.2e-05
Eonia367.51588326690173.7170424.98553e-061e-06
Werkloosheid6.359123825988271.6074543.9560.000157.5e-05
Consumentenvertrouwen68.391966647122310.0267096.82100
Goudprijs-0.04552055599046350.026444-1.72140.0885410.044271
Olieprijs2.570327459344264.0865120.6290.5309220.265461
CPI94.234895243276230.1811423.12230.0023990.001199


Multiple Linear Regression - Regression Statistics
Multiple R0.881398336649735
R-squared0.77686302784892
Adjusted R-squared0.762310616621676
F-TEST (value)53.3838011940258
F-TEST (DF numerator)6
F-TEST (DF denominator)92
p-value0
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation421.280954316181
Sum Squared Residuals16327943.1071988


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
12065.812660.47146553959-594.661465539592
21940.492616.83800838873-676.348008388734
320422474.61566876974-432.61566876974
41995.372144.15792581634-148.787925816341
51946.812049.61827934952-102.808279349525
61765.91833.63376675629-67.7337667562919
71635.251493.12722408055142.122775919451
81833.421876.93069119458-43.510691194575
91910.431926.24274929894-15.8127492989441
101959.671806.23998968478153.430010315221
111969.61966.381920069393.21807993060592
122061.412191.83355195561-130.423551955614
132093.482562.78112364175-469.301123641754
142120.881782.83597559228338.044024407724
152174.562274.69154985883-100.131549858834
162196.722356.31736521654-159.597365216539
172350.442629.44496667042-279.004966670423
182440.252815.08804381624-374.838043816238
192408.642638.9592382049-230.319238204897
202472.812574.37450590810-101.564505908105
212407.62448.83603718329-41.2360371832928
222454.622888.25888506093-433.638885060934
232448.052993.95401507101-545.904015071008
242497.843245.01366204519-747.173662045187
252645.643268.17709643133-622.537096431327
262756.763065.73038226049-308.970382260494
272849.272853.99664692998-4.72664692998368
282921.442878.1976816631043.2423183369031
292981.852914.1723236528967.6776763471097
303080.583174.39765591537-93.8176559153698
313106.223296.79132892676-190.571328926757
323119.313050.0535169462869.2564830537203
333061.262607.58991824019453.670081759806
343097.312629.91983350500467.390166495005
353161.693037.94637272667123.743627273332
363257.163174.9298651217682.230134878244
373277.012895.38082909896381.629170901039
383295.323136.26220113067159.057798869330
393363.992935.69741396033428.292586039667
403494.173257.71671958524236.45328041476
413667.033508.46653345497158.563466545033
423813.063455.080910652357.979089348001
433917.963250.41192751311667.54807248689
443895.513338.08322841624557.426771583757
453801.063180.65957191671620.400428083285
463570.123576.89127414298-6.77127414297942
473701.613926.66174375049-225.051743750485
483862.274047.15347343285-184.883473432851
493970.14008.70580416341-38.6058041634125
504138.524140.93597963593-2.41597963592912
514199.753946.181792495253.568207505
524290.893374.45601436162916.433985638376
534443.913874.69404771795569.21595228205
544502.643974.51545785273528.124542147266
554356.983802.9910802816553.988919718403
564591.274073.28497571189517.985024288106
574696.963963.46632746312733.49367253688
584621.43897.23108859242724.168911407575
594562.844220.47759376793342.36240623207
604202.524183.9964918836818.5235081163171
614296.494019.03015602455277.459843975450
624435.234005.98121039268429.24878960732
634105.183554.66895586673550.511044133266
644116.683827.83214527474288.847854725265
653844.493737.82149166792106.668508332083
663720.983944.71015158458-223.730151584578
673674.43982.25302195050-307.853021950496
683857.623767.1900888784790.4299111215302
693801.063655.16480840234145.895191597661
703504.373667.00342221297-162.633422212971
713032.63950.60301208027-918.00301208027
723047.034089.86934628124-1042.83934628124
732962.344077.62554796322-1115.28554796322
742197.823148.24307756284-950.42307756284
752014.452430.43983648513-415.989836485125
761862.831994.61213878252-131.782138782521
771905.412125.3367255358-219.926725535800
781810.991593.73973972590217.250260274095
791670.071508.45167419612161.618325803883
801864.441656.53171866965207.908281330349
812052.021759.77633986968292.243660130324
822029.61888.12141840814141.478581591865
832070.832157.45338412514-86.6233841251424
842293.412679.30972323161-385.899723231608
852443.272512.04819969509-68.7781996950871
862513.172325.05869746198188.111302538024
872466.922390.8756601862776.044339813729
882502.662137.70189183755364.958108162446
892539.912215.41459645775324.495403542252
902482.62202.38993437706280.210065622942
912626.152294.93191785381331.218082146188
922656.322573.5726057654182.7473942345863
932446.662018.00098667355428.659013326446
942467.382260.03731588889207.342684111109
952462.322908.70866695699-446.388666956988
962504.583123.83173177044-619.251731770442
972579.393008.88390950980-429.493909509798
982649.243139.98261960826-490.742619608263
992636.873110.05041830919-473.180418309193


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
100.005217612989190880.01043522597838180.99478238701081
110.0006669857663933960.001333971532786790.999333014233607
120.0001090189632770510.0002180379265541020.999890981036723
131.92461650155865e-053.84923300311731e-050.999980753834984
143.00515311558955e-056.01030623117911e-050.999969948468844
151.15991983850039e-052.31983967700079e-050.999988400801615
164.05313183110562e-068.10626366221125e-060.999995946868169
173.68211375031608e-067.36422750063215e-060.99999631788625
182.12717480554364e-064.25434961108728e-060.999997872825194
198.58828746667192e-071.71765749333438e-060.999999141171253
201.06696454570641e-062.13392909141282e-060.999998933035454
213.18220394967864e-076.36440789935727e-070.999999681779605
222.56123078860147e-075.12246157720294e-070.999999743876921
231.38278011229511e-072.76556022459022e-070.999999861721989
241.59156257646122e-073.18312515292243e-070.999999840843742
251.53922197767340e-073.07844395534679e-070.999999846077802
262.95075586104447e-075.90151172208894e-070.999999704924414
276.33615137271968e-061.26723027454394e-050.999993663848627
280.0001779439199197110.0003558878398394230.99982205608008
290.0009125811155852390.001825162231170480.999087418884415
300.001641609613270220.003283219226540450.99835839038673
310.002228499196612960.004456998393225930.997771500803387
320.002964408116925550.00592881623385110.997035591883074
330.002990765661002410.005981531322004830.997009234338998
340.002718896926255510.005437793852511010.997281103073745
350.001708613762956520.003417227525913050.998291386237043
360.001062650371013590.002125300742027190.998937349628986
370.0006643591999040510.001328718399808100.999335640800096
380.00040834475606590.00081668951213180.999591655243934
390.0002909492878877980.0005818985757755950.999709050712112
400.0002517360861621140.0005034721723242280.999748263913838
410.0004152121904949270.0008304243809898540.999584787809505
420.0003974672893178330.0007949345786356660.999602532710682
430.0005090087969718610.001018017593943720.999490991203028
440.0004308662520944580.0008617325041889160.999569133747906
450.0008451660751810740.001690332150362150.999154833924819
460.02870777364447990.05741554728895970.97129222635552
470.1204016174343180.2408032348686370.879598382565682
480.1613815280601880.3227630561203770.838618471939812
490.1702722155866120.3405444311732230.829727784413388
500.2773808834191570.5547617668383150.722619116580843
510.3734121240187060.7468242480374130.626587875981294
520.4127544247143990.8255088494287980.587245575285601
530.3735020732718510.7470041465437030.626497926728149
540.3266276678883890.6532553357767790.67337233211161
550.281486445427330.562972890854660.71851355457267
560.2415259112612720.4830518225225440.758474088738728
570.2515175958463860.5030351916927710.748482404153614
580.2257924863740620.4515849727481230.774207513625938
590.2923607756066950.584721551213390.707639224393305
600.3628167085744860.7256334171489710.637183291425514
610.3528263951193880.7056527902387770.647173604880612
620.3862213438325760.7724426876651510.613778656167424
630.5530476198451870.8939047603096260.446952380154813
640.7708942775449930.4582114449100150.229105722455008
650.9376938338984070.1246123322031860.0623061661015929
660.990900738968440.01819852206311900.00909926103155948
670.996878510629240.006242978741519260.00312148937075963
680.9987337563916520.002532487216696650.00126624360834833
690.9998929432856280.0002141134287430990.000107056714371550
700.9999466235784380.000106752843124015.3376421562005e-05
710.999994560209321.08795813587910e-055.43979067939548e-06
720.9999986427993632.71440127450587e-061.35720063725294e-06
730.9999998498834873.00233026834413e-071.50116513417206e-07
740.999999981018923.79621608070757e-081.89810804035378e-08
750.9999999473639021.05272196314472e-075.2636098157236e-08
760.9999997992850274.01429945951499e-072.00714972975750e-07
770.9999997539088374.92182327015862e-072.46091163507931e-07
780.9999997468643825.0627123642627e-072.53135618213135e-07
790.9999988874590322.22508193548400e-061.11254096774200e-06
800.9999957840077018.43198459739873e-064.21599229869936e-06
810.9999966166623736.76667525405852e-063.38333762702926e-06
820.9999897296984542.05406030921802e-051.02703015460901e-05
830.9999964933953767.01320924768119e-063.50660462384059e-06
840.9999998506316642.98736672821897e-071.49368336410949e-07
850.999998522288432.95542314020312e-061.47771157010156e-06
860.9999911058265471.77883469055777e-058.89417345278886e-06
870.9999642885722367.14228555286263e-053.57114277643131e-05
880.9996439794983770.000712041003245430.000356020501622715
890.9971213387502250.005757322499549960.00287866124977498


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level580.725NOK
5% type I error level600.75NOK
10% type I error level610.7625NOK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/10z5jg1292426076.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/10z5jg1292426076.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/1amm41292426076.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/1amm41292426076.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/23dlp1292426076.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/23dlp1292426076.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/33dlp1292426076.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/33dlp1292426076.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/43dlp1292426076.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/43dlp1292426076.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/53dlp1292426076.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/53dlp1292426076.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/6w4291292426076.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/6w4291292426076.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/7ow2d1292426076.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/7ow2d1292426076.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/8ow2d1292426076.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/8ow2d1292426076.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/9ow2d1292426076.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/15/t1292426070sp2yban07lgjyi9/9ow2d1292426076.ps (open in new window)


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