Home » date » 2008 » Dec » 16 »

Multiple Linear Regression

*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: Tue, 16 Dec 2008 12:51: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/16/t1229457127w46x33fw7m06epy.htm/, Retrieved Tue, 16 Dec 2008 20:52:17 +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/16/t1229457127w46x33fw7m06epy.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 «
205597 0 205471 0 211064 0 212856 0 217036 0 219302 0 219759 0 221388 0 220834 0 221788 0 222358 0 222972 0 224164 0 224915 0 226294 0 224690 0 227021 0 229284 0 229189 0 230032 0 229389 0 231053 0 232560 0 232681 0 231555 0 231428 0 232141 0 234939 0 235424 0 235471 0 236355 0 238693 0 236958 0 237060 0 239282 0 238252 0 241552 0 236230 0 238909 0 240723 0 242120 0 242100 0 243276 0 244677 0 243494 0 244902 0 245247 0 245578 0 243052 0 238121 0 241863 0 241203 0 243634 0 242351 0 245180 0 246126 0 244424 0 245166 0 247258 0 245094 0 246020 0 243082 0 245555 0 243685 0 247277 0 245029 0 246169 0 246778 0 244577 0 246048 0 245775 0 245328 0 245477 0 241903 0 243219 0 248088 0 248521 0 247389 0 249057 0 248916 0 249193 0 250768 1 253106 1 249829 1 249447 1 246755 1 250785 1 250140 1 255755 1 254671 1 253919 1 253741 1 252729 1 253810 1 256653 1 255231 1 258405 1 251061 1 254811 1 254895 1 258325 1 257608 1 258759 1 258621 1 257852 1 260560 1 262358 1 260812 1 261165 1 257164 1 260720 1 259581 1 264743 1 261845 1 262262 1 261631 1 258953 1 259966 1 262850 1 262204 1 263418 1 262752 1 266433 1 267722 1 266003 1 262971 1 265521 1 264676 1 270223 1 269508 1 268457 1 265814 1 266680 1 263018 1 269285 1 269829 1 270911 1 266844 1 271244 1 269907 1 271296 1 270157 1 271322 1 267179 1 264101 1 265518 1 269419 1 268714 1 272482 1 268351 1 268175 1 270674 1 272764 1 272599 1 270333 1 270846 1 270491 1 269160 1 274027 1 273784 1 276663 1 274525 1 271344 1 271115 1 270798 1 273911 1 273985 1 271917 1 273338 1 270601 1 273547 1 275363 1 281229 1 277793 1 279913 1 282500 1 280041 1 282166 1 290304 1 283519 1 287816 1 285226 1 287595 1 289741 1 289148 1 288301 0 290155 0 289648 0 288225 0 289351 0 294735 0 305333 0
 
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'George Udny Yule' @ 72.249.76.132


Multiple Linear Regression - Estimated Regression Equation
Brutoschuld[t] = + 223036.069848789 -3280.17593296528Dummy[t] -1711.30752207312M1[t] -4560.92729279379M2[t] -1589.60956351440M3[t] -1304.29183423502M4[t] + 859.338395044333M5[t] -1106.79237148660M6[t] -436.724642207233M7[t] -241.406912927854M8[t] -1059.77668364848M9[t] -145.88545855878M10[t] + 1232.1822707206M11[t] + 357.557270720626t + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)223036.0698487891125.608167198.147200
Dummy-3280.17593296528840.026763-3.90480.0001346.7e-05
M1-1711.307522073121403.219202-1.21960.2242460.112123
M2-4560.927292793791402.792242-3.25130.0013740.000687
M3-1589.609563514401402.405833-1.13350.2585340.129267
M4-1304.291834235021402.060008-0.93030.3534920.176746
M5859.3383950443331401.7547980.6130.5406290.270315
M6-1106.792371486601401.235681-0.78990.4306550.215328
M7-436.7246422072331401.218109-0.31170.7556520.377826
M8-241.4069129278541401.241252-0.17230.8634130.431706
M9-1059.776683648481401.305108-0.75630.4504820.225241
M10-145.885458558781400.838768-0.10410.9171740.458587
M111232.18227072061400.7776780.87960.380240.19012
t357.5572707206267.55315947.338800


Multiple Linear Regression - Regression Statistics
Multiple R0.97999376366391
R-squared0.960387776820155
Adjusted R-squared0.957494749284548
F-TEST (value)331.966344944853
F-TEST (DF numerator)13
F-TEST (DF denominator)178
p-value0
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation3961.9399831563
Sum Squared Residuals2794060380.56360


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
1205597221682.319597436-16085.3195974361
2205471219190.257097437-13719.2570974367
3211064222519.132097437-11455.1320974366
4212856223162.007097437-10306.0070974366
5217036225683.194597437-8647.19459743666
6219302224074.621101626-4772.62110162627
7219759225102.246101626-5343.24610162624
8221388225655.121101626-4267.1211016263
9220834225194.308601626-4360.30860162628
10221788226465.757097437-4677.75709743664
11222358228201.382097437-5843.38209743662
12222972227326.757097437-4354.75709743664
13224164225973.006846084-1809.00684608416
14224915223480.9443460841434.05565391593
15226294226809.819346084-515.819346084138
16224690227452.694346084-2762.69434608415
17227021229973.881846084-2952.88184608414
18229284228365.308350274918.691649726187
19229189229392.933350274-203.933350273815
20230032229945.80835027486.191649726191
21229389229484.995850274-95.9958502738156
22231053230756.444346084296.555653915858
23232560232492.06934608467.930653915857
24232681231617.4443460841063.55565391583
25231555230263.6940947321291.30590526832
26231428227771.6315947323656.36840526835
27232141231100.5065947321040.49340526835
28234939231743.3815947323195.61840526834
29235424234264.5690947321159.43090526835
30235471232655.9955989212815.00440107867
31236355233683.6205989212671.37940107867
32238693234236.4955989214456.50440107868
33236958233775.6830989213182.31690107867
34237060235047.1315947322012.86840526835
35239282236782.7565947322499.24340526834
36238252235908.1315947322343.86840526832
37241552234554.3813433796997.6186566208
38236230232062.3188433794167.68115662084
39238909235391.1938433793517.80615662084
40240723236034.0688433794688.93115662082
41242120238555.2563433793564.74365662083
42242100236946.6828475695153.31715243116
43243276237974.3078475695301.69215243116
44244677238527.1828475696149.81715243116
45243494238066.3703475695427.62965243116
46244902239337.8188433795564.18115662083
47245247241073.4438433794173.55615662083
48245578240198.8188433795379.1811566208
49243052238845.0685920274206.93140797329
50238121236353.0060920271767.99390797332
51241863239681.8810920272181.11890797333
52241203240324.756092027878.24390797331
53243634242845.943592027788.056407973321
54242351241237.3700962161113.62990378365
55245180242264.9950962162915.00490378365
56246126242817.8700962163308.12990378365
57244424242357.0575962162066.94240378364
58245166243628.5060920271537.49390797332
59247258245364.1310920271893.86890797332
60245094244489.506092027604.493907973291
61246020243135.7558406742884.24415932577
62243082240643.6933406742438.30665932581
63245555243972.5683406741582.43165932581
64243685244615.443340674-930.443340674203
65247277247136.630840674140.369159325806
66245029245528.057344864-499.057344863868
67246169246555.682344864-386.682344863869
68246778247108.557344864-330.557344863865
69244577246647.744844864-2070.74484486387
70246048247919.193340674-1871.19334067420
71245775249654.818340674-3879.8183406742
72245328248780.193340674-3452.19334067422
73245477247426.443089322-1949.44308932174
74241903244934.380589322-3031.38058932171
75243219248263.255589322-5044.2555893217
76248088248906.130589322-818.130589321715
77248521251427.318089322-2906.31808932171
78247389249818.744593511-2429.74459351138
79249057250846.369593511-1789.36959351138
80248916251399.244593511-2483.24459351138
81249193250938.432093511-1745.43209351138
82250768248929.7046563561838.29534364359
83253106250665.3296563562440.67034364359
84249829249790.70465635638.2953436435610
85249447248436.9544050041010.04559499605
86246755245944.891905004810.108094996088
87250785249273.7669050041511.23309499608
88250140249916.641905004223.358094996073
89255755252437.8294050043317.17059499608
90254671250829.2559091943841.7440908064
91253919251856.8809091942062.1190908064
92253741252409.7559091941331.24409080640
93252729251948.943409194780.056590806406
94253810253220.391905004589.608094996074
95256653254956.0169050041696.98309499607
96255231254081.3919050041149.60809499605
97258405252727.6416536515677.35834634854
98251061250235.579153651825.420846348572
99254811253564.4541536511246.54584634857
100254895254207.329153651687.670846348554
101258325256728.5166536511596.48334634857
102257608255119.9431578412488.05684215889
103258759256147.5681578412611.43184215889
104258621256700.4431578411920.55684215890
105257852256239.6306578411612.36934215889
106260560257511.0791536513048.92084634856
107262358259246.7041536513111.29584634856
108260812258372.0791536512439.92084634853
109261165257018.3289022994146.67109770102
110257164254526.2664022992637.73359770105
111260720257855.1414022992864.85859770106
112259581258498.0164022991082.98359770104
113264743261019.2039022993723.79609770105
114261845259410.6304064892434.36959351138
115262262260438.2554064891823.74459351138
116261631260991.130406489639.869593511381
117258953260530.317906489-1577.31790648862
118259966261801.766402299-1835.76640229895
119262850263537.391402299-687.391402298951
120262204262662.766402299-458.766402298977
121263418261309.0161509462108.98384905351
122262752258816.9536509463935.04634905354
123266433262145.8286509464287.17134905354
124267722262788.7036509464933.29634905353
125266003265309.891150946693.10884905354
126262971263701.317655136-730.317655136134
127265521264728.942655136792.057344863864
128264676265281.817655136-605.817655136132
129270223264821.0051551365401.99484486387
130269508266092.4536509463415.54634905354
131268457267828.078650946628.921349053534
132265814266953.453650946-1139.45365094649
133266680265599.7033995941080.29660040599
134263018263107.640899594-89.6408995939712
135269285266436.5158995942848.48410040603
136269829267079.3908995942749.60910040602
137270911269600.5783995941310.42160040603
138266844267992.004903784-1148.00490378365
139271244269019.6299037842224.37009621635
140269907269572.504903784334.495096216354
141271296269111.6924037842184.30759621635
142270157270383.140899594-226.140899593977
143271322272118.765899594-796.765899593979
144267179271244.140899594-4065.14089959400
145264101269890.390648242-5789.39064824152
146265518267398.328148242-1880.32814824148
147269419270727.203148242-1308.20314824148
148268714271370.078148242-2656.0781482415
149272482273891.265648242-1409.26564824149
150268351272282.692152431-3931.69215243116
151268175273310.317152431-5135.31715243116
152270674273863.192152431-3189.19215243116
153272764273402.379652431-638.379652431164
154272599274673.828148242-2074.82814824149
155270333276409.453148242-6076.45314824149
156270846275534.828148242-4688.82814824152
157270491274181.077896889-3690.07789688903
158269160271689.015396889-2529.015396889
159274027275017.890396889-990.890396888999
160273784275660.765396889-1876.76539688901
161276663278181.952896889-1518.95289688900
162274525276573.379401079-2048.37940107868
163271344277601.004401079-6257.00440107868
164271115278153.879401079-7038.87940107868
165270798277693.066901079-6895.06690107868
166273911278964.515396889-5053.51539688901
167273985280700.140396889-6715.14039688901
168271917279825.515396889-7908.51539688904
169273338278471.765145537-5133.76514553655
170270601275979.702645537-5378.70264553651
171273547279308.577645537-5761.57764553651
172275363279951.452645537-4588.45264553653
173281229282472.640145537-1243.64014553652
174277793280864.066649726-3071.06664972619
175279913281891.691649726-1978.69164972619
176282500282444.56664972655.4333502738082
177280041281983.754149726-1942.75414972619
178282166283255.202645537-1089.20264553652
179290304284990.8276455375313.17235446348
180283519284116.202645537-597.202645536546
181287816282762.4523941845053.54760581594
182285226280270.3898941844955.61010581598
183287595283599.2648941843995.73510581597
184289741284242.1398941845498.86010581596
185289148286763.3273941842384.67260581598
186288301288434.929831339-133.929831339018
187290155289462.554831339692.445168661002
188289648290015.429831339-367.429831339003
189288225289554.617331339-1329.61733133899
190289351290826.065827149-1475.06582714933
191294735292561.6908271492173.30917285067
192305333291687.06582714913645.9341728506


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
170.677953437996090.6440931240078210.322046562003911
180.6636689034398180.6726621931203630.336331096560182
190.6454449590838350.709110081832330.354555040916165
200.6369729132064120.7260541735871770.363027086793588
210.6117761708144980.7764476583710030.388223829185502
220.5509088063494680.8981823873010640.449091193650532
230.4667481663823450.9334963327646910.533251833617655
240.3921506520111390.7843013040222780.607849347988861
250.3097971090089520.6195942180179030.690202890991048
260.2395165490684320.4790330981368630.760483450931568
270.2341667672413840.4683335344827680.765833232758616
280.1740923963496800.3481847926993590.82590760365032
290.1598264634443980.3196529268887960.840173536555602
300.1984819588107760.3969639176215520.801518041189224
310.1972207705201600.3944415410403190.80277922947984
320.1682514600878460.3365029201756930.831748539912154
330.1568566976742570.3137133953485140.843143302325743
340.1663055710986330.3326111421972650.833694428901367
350.1456658257003520.2913316514007050.854334174299648
360.1475680030482850.295136006096570.852431996951715
370.1294149052239240.2588298104478470.870585094776076
380.1265377491079820.2530754982159640.873462250892018
390.1157376005807250.2314752011614510.884262399419275
400.09640884164479130.1928176832895830.903591158355209
410.08490222727464590.1698044545492920.915097772725354
420.09408216320799930.1881643264159990.905917836792
430.09008599623083460.1801719924616690.909914003769165
440.09034520732947560.1806904146589510.909654792670524
450.08861771640931980.1772354328186400.91138228359068
460.08184977883514010.1636995576702800.91815022116486
470.08045409985307170.1609081997061430.919545900146928
480.07781734125348120.1556346825069620.922182658746519
490.0813812262350650.162762452470130.918618773764935
500.1521302660702530.3042605321405060.847869733929747
510.1878074613106570.3756149226213140.812192538689343
520.2727063071946250.5454126143892510.727293692805375
530.3335080552740330.6670161105480650.666491944725967
540.4764271979284050.952854395856810.523572802071595
550.51762622381640.96474755236720.4823737761836
560.5711331092907520.8577337814184960.428866890709248
570.6225127510339410.7549744979321180.377487248966059
580.6660829604244930.6678340791510140.333917039575507
590.6779397848021390.6441204303957220.322060215197861
600.730023521171080.5399529576578390.269976478828920
610.718020119279440.5639597614411210.281979880720561
620.7164822489623380.5670355020753230.283517751037662
630.7122094887209950.5755810225580090.287790511279005
640.754233058610230.491533882779540.24576694138977
650.7574816021712840.4850367956574310.242518397828716
660.807153945263720.3856921094725610.192846054736281
670.8395614682299860.3208770635400280.160438531770014
680.8730277281657210.2539445436685580.126972271834279
690.9083414134479880.1833171731040240.091658586552012
700.9267969756358810.1464060487282370.0732030243641187
710.9546428585381540.09071428292369120.0453571414618456
720.9703710009710180.05925799805796320.0296289990289816
730.9731383330819640.05372333383607160.0268616669180358
740.9798852693844820.04022946123103670.0201147306155184
750.9906703338267880.01865933234642450.00932966617321227
760.9899460451583570.02010790968328530.0100539548416427
770.993019866837860.01396026632428270.00698013316214135
780.9951453228934450.009709354213109120.00485467710655456
790.9963843045645370.007231390870925150.00361569543546257
800.9980998450838320.00380030983233660.0019001549161683
810.9990996400072120.001800719985576470.000900359992788233
820.998692347853580.002615304292840800.00130765214642040
830.9981379711883570.003724057623285660.00186202881164283
840.9975872821057740.004825435788451640.00241271789422582
850.9968005393347240.006398921330552410.00319946066527621
860.9958288748111530.008342250377693190.00417112518884659
870.9946434380974830.01071312380503370.00535656190251683
880.99366967153920.01266065692159950.00633032846079976
890.9919049121370260.01619017572594740.00809508786297372
900.9898581936231030.02028361275379410.0101418063768970
910.9864985806420360.02700283871592880.0135014193579644
920.9825133259440120.03497334811197690.0174866740559885
930.9777310449668020.04453791006639520.0222689550331976
940.9721958004855060.05560839902898740.0278041995144937
950.9643436319033720.07131273619325560.0356563680966278
960.955223150478020.0895536990439590.0447768495219795
970.9531567594997990.09368648100040280.0468432405002014
980.943750188393840.1124996232123190.0562498116061597
990.9330996966283350.133800606743330.0669003033716649
1000.9230259824014450.1539480351971100.0769740175985552
1010.9082360247623810.1835279504752380.0917639752376192
1020.8905788556672420.2188422886655150.109421144332758
1030.8706742380903150.2586515238193700.129325761909685
1040.848483705488580.3030325890228380.151516294511419
1050.8213424170077210.3573151659845570.178657582992279
1060.7970227945667140.4059544108665720.202977205433286
1070.7700646419256460.4598707161487090.229935358074354
1080.7373106052950960.5253787894098070.262689394704904
1090.7145201896134930.5709596207730140.285479810386507
1100.6757820705400430.6484358589199140.324217929459957
1110.6351435510038950.729712897992210.364856448996105
1120.5976815377151960.8046369245696080.402318462284804
1130.5600917380262040.8798165239475920.439908261973796
1140.533799208481680.932401583036640.46620079151832
1150.5017585687493570.9964828625012860.498241431250643
1160.4705500476024340.9411000952048670.529449952397566
1170.4544837100440940.9089674200881890.545516289955906
1180.4435746540086020.8871493080172050.556425345991398
1190.414011505521780.828023011043560.58598849447822
1200.3815243031027570.7630486062055130.618475696897243
1210.346068916059570.692137832119140.65393108394043
1220.3231527720022910.6463055440045820.676847227997709
1230.3010589410124050.602117882024810.698941058987595
1240.2906941986956110.5813883973912210.709305801304389
1250.2548040158053010.5096080316106020.745195984194699
1260.2352605022522380.4705210045044750.764739497747762
1270.2158038044759110.4316076089518230.784196195524089
1280.1967136512515470.3934273025030940.803286348748453
1290.2410699901408480.4821399802816950.758930009859152
1300.2588085619369840.5176171238739680.741191438063016
1310.2371338765877040.4742677531754090.762866123412296
1320.2130530669027570.4261061338055140.786946933097243
1330.2008044669370120.4016089338740250.799195533062988
1340.1768500400572230.3537000801144460.823149959942777
1350.1705284542827630.3410569085655270.829471545717237
1360.1659689607488490.3319379214976990.83403103925115
1370.1479465437149830.2958930874299660.852053456285017
1380.1433153200948470.2866306401896930.856684679905153
1390.1948364159424870.3896728318849750.805163584057513
1400.2199951688370420.4399903376740830.780004831162958
1410.3118252829993580.6236505659987150.688174717000642
1420.3617657858474240.7235315716948490.638234214152576
1430.3837312992618340.7674625985236670.616268700738166
1440.3662582303062890.7325164606125780.633741769693711
1450.3735126950599560.7470253901199120.626487304940044
1460.3500083759797550.700016751959510.649991624020245
1470.3330674782922060.6661349565844130.666932521707794
1480.3036866006202540.6073732012405080.696313399379746
1490.2806603431679370.5613206863358740.719339656832063
1500.2702264186986610.5404528373973230.729773581301339
1510.2665237299732630.5330474599465260.733476270026737
1520.2764415192789080.5528830385578150.723558480721092
1530.4078065100653570.8156130201307140.592193489934643
1540.5059241696590170.9881516606819650.494075830340983
1550.4770447328478990.9540894656957990.522955267152101
1560.4319002148344230.8638004296688460.568099785165577
1570.3920367059687470.7840734119374940.607963294031253
1580.3729570645120950.745914129024190.627042935487905
1590.437065080949610.874130161899220.56293491905039
1600.4678169472455580.9356338944911150.532183052754442
1610.5693800921911070.8612398156177860.430619907808893
1620.6997500005608780.6004999988782430.300249999439122
1630.6815084211929540.6369831576140930.318491578807046
1640.6453731558572270.7092536882855460.354626844142773
1650.6526454818066560.6947090363866870.347354518193344
1660.7455127043900970.5089745912198060.254487295609903
1670.6786861911774710.6426276176450570.321313808822529
1680.668562687616120.662874624767760.33143731238388
1690.5867908963394350.826418207321130.413209103660565
1700.5048923078464820.9902153843070360.495107692153518
1710.4212056729169220.8424113458338440.578794327083078
1720.3816773378819340.7633546757638680.618322662118066
1730.2689483016089810.5378966032179610.73105169839102
1740.1711452288433450.3422904576866890.828854771156655
1750.09315372599685310.1863074519937060.906846274003147


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level90.0566037735849057NOK
5% type I error level200.125786163522013NOK
10% type I error level270.169811320754717NOK
 
Charts produced by software:
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/10ahyj1229457081.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/10ahyj1229457081.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/1trbo1229457081.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/1trbo1229457081.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/29i6c1229457081.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/29i6c1229457081.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/3bll61229457081.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/3bll61229457081.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/4eklq1229457081.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/4eklq1229457081.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/5qcqk1229457081.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/5qcqk1229457081.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/6patb1229457081.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/6patb1229457081.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/7b1gd1229457081.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/7b1gd1229457081.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/8kxtr1229457081.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/8kxtr1229457081.ps (open in new window)


http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/9azii1229457081.png (open in new window)
http://127.0.0.1/wessadotnet/public_html/freestatisticsdotorg/blog/date/2008/Dec/16/t1229457127w46x33fw7m06epy/9azii1229457081.ps (open in new window)


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





Copyright

Creative Commons License

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

Software written by Ed van Stee & Patrick Wessa


Disclaimer

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


Privacy Policy

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

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

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

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

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

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

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

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

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


FreeStatistics.org is powered by