Home » date » 2010 » Dec » 22 »

*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, 22 Dec 2010 19:51:26 +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/22/t1293047359sv7kksvxxtm2r1t.htm/, Retrieved Wed, 22 Dec 2010 20:49:30 +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/22/t1293047359sv7kksvxxtm2r1t.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 «
-0.03086 -0.01025 0.04860 0.04399 -0.03429 0.00779 0.00149 0.01848 0.00338 0.00099 -0.01826 0.04033 -0.03086 -0.01025 0.04860 0.04399 -0.03429 0.01244 0.00149 0.01848 0.00338 0.00099 -0.02352 0.04033 -0.03086 -0.01025 0.04860 0.04399 0.01150 0.01244 0.00149 0.01848 0.00338 0.00573 -0.02352 0.04033 -0.03086 -0.01025 0.04860 -0.00793 0.01150 0.01244 0.00149 0.01848 0.01805 0.00573 -0.02352 0.04033 -0.03086 -0.01025 -0.01514 -0.00793 0.01150 0.01244 0.00149 -0.01887 0.01805 0.00573 -0.02352 0.04033 -0.03086 0.01778 -0.01514 -0.00793 0.01150 0.01244 0.04363 -0.01887 0.01805 0.00573 -0.02352 0.04033 0.00634 0.01778 -0.01514 -0.00793 0.01150 0.02875 0.04363 -0.01887 0.01805 0.00573 -0.02352 0.00770 0.00634 0.01778 -0.01514 -0.00793 -0.00393 0.02875 0.04363 -0.01887 0.01805 0.00573 0.00692 0.00770 0.00634 0.01778 -0.01514 0.05280 -0.00393 0.02875 0.04363 -0.01887 0.01805 0.00029 0.00692 0.00770 0.00634 0.01778 -0.00351 0.05280 -0.00393 0.02875 0.04363 -0.01887 0.02487 0.00029 0.00692 0.00770 0.00634 0.054 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


Multiple Linear Regression - Estimated Regression Equation
(1-B)lnYt[t] = + 0.00298687237561425 + 0.279841978072988`(1-B)lnY_[t-1]`[t] + 0.0924602034106877`(1-B)lnY_[t-2]`[t] -0.0999401043206112`(1-B)lnY_[t-3]`[t] -0.133172004343059`(1-B)lnY_[t-4]`[t] -0.131646989364628`(1-B)lnY_[t-5]`[t] + 0.630660827401185`(1-B)lnX_[t-1]`[t] -0.338975843529546`(1-B)lnX_[t-2]`[t] + 0.510544531512295`(1-B)lnX_[t-3]`[t] -0.405092174192946`(1-B)lnX_[t-4]`[t] + 0.148230264174965`(1-B)lnX_[t-5]`[t] + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)0.002986872375614250.0053390.55940.5773820.288691
`(1-B)lnY_[t-1]`0.2798419780729880.1113262.51370.0138550.006928
`(1-B)lnY_[t-2]`0.09246020341068770.1277830.72360.471340.23567
`(1-B)lnY_[t-3]`-0.09994010432061120.125216-0.79810.4270390.21352
`(1-B)lnY_[t-4]`-0.1331720043430590.121284-1.0980.2753350.137667
`(1-B)lnY_[t-5]`-0.1316469893646280.125205-1.05150.2960660.148033
`(1-B)lnX_[t-1]`0.6306608274011850.2746832.2960.0241690.012085
`(1-B)lnX_[t-2]`-0.3389758435295460.270783-1.25180.2141040.107052
`(1-B)lnX_[t-3]`0.5105445315122950.2642831.93180.0567550.028377
`(1-B)lnX_[t-4]`-0.4050921741929460.268436-1.50910.135030.067515
`(1-B)lnX_[t-5]`0.1482302641749650.2436340.60840.5445540.272277


Multiple Linear Regression - Regression Statistics
Multiple R0.540465013479973
R-squared0.292102430795908
Adjusted R-squared0.207828910652563
F-TEST (value)3.46612352609762
F-TEST (DF numerator)10
F-TEST (DF denominator)84
p-value0.000752185537719718
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation0.0487324103769968
Sum Squared Residuals0.19948721697677


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
1-0.03086-0.00295004353653766-0.0279099564634623
20.040330.002754827612722550.0375751723872775
3-0.02352-0.00300798064250723-0.0205120193574928
40.00573-0.002227450611842290.0079574506118423
50.01805-0.001963159715095680.0200131597150957
6-0.018870.0190922575860881-0.0379622575860881
70.04363-0.00821582949570980.0518458294957098
80.028750.0307230893782364-0.00197308937823643
9-0.003930.00933831196456645-0.0132683119645664
100.05280.002157286470272570.0506427135297274
11-0.003510.0281395364335619-0.0316495364335619
120.05407-0.001465612081896270.0555356120818963
13-0.012990.0330896671455471-0.0460796671455471
140.007470.006776082745153310.000693917254846692
15-0.032880.0082671282298679-0.0411471282298679
16-0.05013-0.00992726424360557-0.0402027357563944
170.03715-0.01662923457593820.0537792345759382
180.00205-0.006059568273305050.00810956827330505
190.029120.0341193585230271-0.00499935852302714
20-0.008320.0107708211865912-0.0190908211865912
210.029080.01316395868264950.0159160413173505
22-0.009420.00580963934823189-0.0152296393482319
230.043810.004230156184742890.0395798438152571
240.006030.0115073360573358-0.00547733605733578
250.022530.01532910068202320.00720089931797678
260.057890.01320866977930450.0446813302206955
27-0.037830.0181211803959200-0.05595118039592
28-0.031760.00891838517239862-0.0406783851723986
29-0.00572-0.03503934108374870.0293193410837487
300.0104-0.004884875064696470.0152848750646965
310.036620.004200912564604380.0324190874353956
320.037710.02142510669992670.0162848933000733
330.059810.03871916862009050.0210908313799095
34-0.032040.00774959784482731-0.0397895978448273
350.028370.0078192943805730.020550705619427
360.05003-0.007977815827876130.0580078158278761
370.04980.03344806747460070.0163519325253993
38-0.022990.0280668608970190-0.051056860897019
390.04030.005772164622424570.0345278353775754
400.031760.001315323846911630.0304446761530884
41-0.001350.0378674526300908-0.0392174526300908
42-0.024730.0165019872321261-0.0412319872321261
43-0.00171-0.02580774102413900.0240977410241390
44-0.015750.0272979939802998-0.0430479939802998
45-0.02624-0.04322763214623900.0169876321462390
460.067240.03510599732412810.0321340026758719
47-0.013620.0223413850163344-0.0359613850163344
48-0.004220.00729291941407819-0.0115129194140782
490.007540.0128583715559720-0.00531837155597196
500.00087-0.01827400982452310.0191440098245231
510.027150.01357892253014200.0135710774698580
520.029760.01383136314272990.0159286368572701
530.079460.04263121250283640.0368287874971636
540.019090.0213437958321560-0.00225379583215603
55-0.024830.00812445947874088-0.0329544594787409
56-0.0187-0.02232757621687670.00362757621687672
570.09682-0.0502011474808970.147021147480897
580.038230.03009393876624980.00813606123375024
590.095710.01590733728930010.0798026627106999
60-0.046630.0230716219180722-0.0697016219180722
61-0.01359-0.02056751440929110.00697751440929106
620.05114-0.01384729052636230.0649872905263623
63-0.042750.00307669910642426-0.0458266991064243
640.057390.02386195667706280.0335280433229371
650.011860.001991223130784380.00986877686921562
660.010660.006203720699194610.00445627930080539
67-0.07387-0.00658866365134271-0.0672813363486573
68-0.04131-0.0185943162843078-0.0227156837156922
69-0.17889-0.0444555147755726-0.134434485224427
70-0.12781-0.0504551548188985-0.0773548451811015
71-0.26933-0.106873303847466-0.162456696152534
72-0.05095-0.05353452053660590.00258452053660586
73-0.01074-0.05006239807371650.0393223980737165
740.081720.06922022911967750.0124997708803225
750.11870.06498333797343680.0537166620265632
760.084750.0979769068198936-0.0132269068198936
770.046630.0536657870585285-0.0070357870585285
78-0.044150.0104575537102259-0.0546075537102259
790.0097-0.01488792297911540.0245879229791154
80-0.03341-0.03560822779338710.00219822779338712
810.040310.02300961129607000.0173003887039300
820.01938-0.01555241890003310.0349324189000331
830.059280.0550944875852930.00418551241470694
840.023430.001072189384414410.0223578106155856
85-0.045360.0388445707983923-0.0842045707983923
860.03355-0.01943300709997720.0529830070999772
870.05659-0.01707025136544300.073660251365443
88-0.065790.0430963815628115-0.108886381562811
89-0.04267-0.00336374700380879-0.0393062529961912
90-0.02422-0.03740383449662730.0131838344966273
910.07584-0.001097360867600830.0769373608676008
92-0.009030.0155580915439419-0.0245880915439419
930.066170.04681394261172530.0193560573882747
940.044850.04009814525944030.0047518547405597
95-0.006650.0167148457951973-0.0233648457951973


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
140.3191502135741450.638300427148290.680849786425855
150.1988411239037320.3976822478074630.801158876096268
160.2655635312350320.5311270624700650.734436468764968
170.2479598538625470.4959197077250930.752040146137454
180.2165562497063110.4331124994126230.783443750293689
190.1374571996804650.2749143993609300.862542800319535
200.0836719771688370.1673439543376740.916328022831163
210.04864328784457470.09728657568914940.951356712155425
220.02867067245023570.05734134490047130.971329327549764
230.01986286066661190.03972572133322380.980137139333388
240.01040059966505420.02080119933010850.989599400334946
250.00573289057490260.01146578114980520.994267109425097
260.008527399578538130.01705479915707630.991472600421462
270.006396507502118650.01279301500423730.993603492497881
280.01174148038804800.02348296077609600.988258519611952
290.00722031347372240.01444062694744480.992779686526278
300.004186188890214870.008372377780429750.995813811109785
310.002403455339123830.004806910678247670.997596544660876
320.001478109439466680.002956218878933350.998521890560533
330.001448566319112480.002897132638224950.998551433680888
340.000911017340697380.001822034681394760.999088982659303
350.0004806981173368480.0009613962346736960.999519301882663
360.0005064331315931350.001012866263186270.999493566868407
370.0004805524112876150.0009611048225752310.999519447588712
380.0002782701379104240.0005565402758208480.99972172986209
390.0004669169029582640.0009338338059165280.999533083097042
400.0004277751559292490.0008555503118584980.99957222484407
410.0002812696334807030.0005625392669614060.99971873036652
420.0001779230741151390.0003558461482302770.999822076925885
430.0001170410832259650.0002340821664519310.999882958916774
447.45114703772047e-050.0001490229407544090.999925488529623
454.38980632655861e-058.77961265311721e-050.999956101936734
462.32752551316538e-054.65505102633077e-050.999976724744868
471.61798897740603e-053.23597795481207e-050.999983820110226
487.77160411642169e-061.55432082328434e-050.999992228395884
493.90432474718083e-067.80864949436167e-060.999996095675253
501.80064328833247e-063.60128657666495e-060.999998199356712
518.2506646789337e-071.65013293578674e-060.999999174933532
523.94551722036872e-077.89103444073743e-070.999999605448278
535.95779233752204e-071.19155846750441e-060.999999404220766
544.77011948463465e-079.5402389692693e-070.999999522988052
552.19137546179377e-074.38275092358755e-070.999999780862454
561.02739635473992e-072.05479270947983e-070.999999897260365
571.08192218136744e-052.16384436273489e-050.999989180778186
586.41924253313564e-061.28384850662713e-050.999993580757467
596.2161016779161e-050.0001243220335583220.99993783898322
600.0001436707141235490.0002873414282470980.999856329285876
610.0003177439380390250.0006354878760780490.99968225606196
620.0004391837406235390.0008783674812470780.999560816259377
630.0007642347175229740.001528469435045950.999235765282477
640.0004638445961527530.0009276891923055070.999536155403847
650.0004993563113659250.000998712622731850.999500643688634
660.0004578573664166310.0009157147328332610.999542142633583
670.0008086458208290550.001617291641658110.999191354179171
680.001188906504348760.002377813008697520.998811093495651
690.02864620110676090.05729240221352180.971353798893239
700.04200764002701830.08401528005403660.957992359972982
710.4936763417983560.9873526835967120.506323658201644
720.4943617030673340.9887234061346680.505638296932666
730.4957594752646450.991518950529290.504240524735355
740.4238387418051590.8476774836103190.576161258194841
750.3701807198102110.7403614396204230.629819280189789
760.2942704076747590.5885408153495180.705729592325241
770.2503789350693950.500757870138790.749621064930605
780.1782533835034210.3565067670068430.821746616496579
790.1341277515463270.2682555030926530.865872248453673
800.07581090848557530.1516218169711510.924189091514425
810.1310763561989070.2621527123978140.868923643801093


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level390.573529411764706NOK
5% type I error level460.676470588235294NOK
10% type I error level500.735294117647059NOK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/10rtaf1293047476.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/10rtaf1293047476.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/13adl1293047476.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/13adl1293047476.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/2v1u61293047476.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/2v1u61293047476.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/3v1u61293047476.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/3v1u61293047476.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/4v1u61293047476.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/4v1u61293047476.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/56su91293047476.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/56su91293047476.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/66su91293047476.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/66su91293047476.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/7zjbt1293047476.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/7zjbt1293047476.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/8zjbt1293047476.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/8zjbt1293047476.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/9rtaf1293047476.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/22/t1293047359sv7kksvxxtm2r1t/9rtaf1293047476.ps (open in new window)


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