Home » date » 2009 » Dec » 17 »

*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: Thu, 17 Dec 2009 21:38:42 +0100
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03.htm/, Retrieved Thu, 17 Dec 2009 21:40:22 +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/2009/Dec/17/t12610824195fwi2n0lvlyhu03.htm/},
    year = {2009},
}
@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 = {2009},
    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 «
277 7.7 0 260.6 7.5 0 291.6 8.3 0 275.4 7.8 0 275.3 7.9 0 231.7 6.6 0 238.8 7 0 274.2 8.2 0 277.8 8.2 0 299.1 9.1 0 286.6 9 0 232.3 7.1 0 294.1 8.9 0 267.5 8.5 0 309.7 9.8 0 280.7 8.8 0 287.3 9.2 0 235.7 7.4 0 256.4 8.3 0 289 9.7 0 290.8 9.7 0 321.9 10.8 0 291.8 9.8 0 241.4 7.9 0 295.5 9.8 0 258.2 9 0 306.1 10.5 0 281.5 9.5 0 283.1 9.7 0 237.4 8.1 0 274.8 10.1 0 299.3 11.1 0 300.4 11.2 0 340.9 12.6 0 318.8 12.2 0 265.7 9.9 0 322.7 11.8 0 281.6 11.1 0 323.5 12.6 0 312.6 11.9 0 310.8 11.9 0 262.8 10 0 273.8 10.8 0 320 12.9 0 310.3 12.5 0 342.2 13.8 0 320.1 13.1 0 265.6 10.5 0 327 12.9 0 300.7 12.9 0 346.4 14.4 0 317.3 12.7 0 326.2 13.3 0 270.7 11 0 278.2 11.9 0 324.6 14.1 0 321.8 14.4 0 343.5 14.9 0 354 15.7 0 278.2 12 0 330.2 14.3 0 307.3 14.2 0 375.9 17.4 0 335.3 15.1 0 339.3 15.3 0 280.3 12.6 0 293.7 14 0 341.2 16.6 0 345.1 16.7 0 368.7 17.6 0 369.4 18.3 0 288.4 13.6 0 341 15.8 0 319.1 16.1 0 374.2 18.6 0 344.5 17.3 0 337.3 17 0 281 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'RServer@AstonUniversity' @ vre.aston.ac.uk


Multiple Linear Regression - Estimated Regression Equation
Y[t][t] = + 209.71550546094 + 4.16064886875658`X[t]`[t] + 35.6139613188847`D[t]`[t] + 44.4881074624471M1[t] + 17.0595132695103M2[t] + 59.9012520404552M3[t] + 42.3320083056181M4[t] + 28.2672223253406M5[t] -5.12091858711014M6[t] + 7.38449939264906M7[t] + 18.1204695726691M8[t] + 31.4270415324802M9[t] + 58.1708547316912M10[t] + 48.8622437145571M11[t] + 0.251010465555662t + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)209.715505460943.46008260.6100
`X[t]`4.160648868756580.40193210.351600
`D[t]`35.613961318884712.3935592.87360.0045730.002287
M144.48810746244714.4899059.908500
M217.05951326951034.4362263.84550.000178.5e-05
M359.90125204045524.95735512.083300
M442.33200830561814.5245939.35600
M528.26722232534064.4144636.403300
M6-5.120918587110144.269829-1.19930.232060.11603
M77.384499392649064.3877311.6830.0942020.047101
M818.12046957266914.4620314.0617.4e-053.7e-05
M931.42704153248024.5806356.860800
M1058.17085473169124.96214811.722900
M1148.86224371455715.0246049.724600
t0.2510104655556620.0821613.05510.0026110.001305


Multiple Linear Regression - Regression Statistics
Multiple R0.985444142850747
R-squared0.971100158678844
Adjusted R-squared0.96873408979875
F-TEST (value)410.427678943987
F-TEST (DF numerator)14
F-TEST (DF denominator)171
p-value0
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation11.8764006811788
Sum Squared Residuals24119.3607269236


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
1277286.491619678368-9.49161967836769
2260.6258.4819061772362.11809382276373
3291.6304.903174508742-13.3031745087422
4275.4285.504616805082-10.1046168050825
5275.3272.1069061772363.19309382276364
6231.7233.560932200958-1.86093220095773
7238.8247.981620193775-9.18162019377515
8274.2263.96137948185910.2386205181412
9277.8277.5189619072260.281038092774518
10299.1308.258369553873-9.15836955387306
11286.6298.784704115419-12.184704115419
12232.3242.26823801578-9.96823801578005
13294.1294.496523907545-0.396523907544678
14267.5265.6546806326611.84531936733911
15309.7314.156273398545-4.45627339854505
16280.7292.677391260507-11.977391260507
17287.3280.5278752932886.77212470671217
18235.7239.901576882631-4.2015768826309
19256.4256.402589309827-0.00258930982670624
20289273.21447837166215.7855216283384
21290.8286.7720607970284.02793920297172
22321.9318.3435982174273.5564017825728
23291.8305.125348797092-13.3253487970922
24241.4248.608882697453-7.2088826974533
25295.5301.253233476094-5.75323347609356
26258.2270.747130653707-12.5471306537071
27306.1320.080853193343-13.9808531933426
28281.5298.601971055304-17.1019710553045
29283.1285.620325314334-2.52032531433405
30237.4245.826156677428-8.42615667742844
31274.8266.9038828602567.89611713974356
32299.3282.05151237458917.2484876254113
33300.4296.0251596868314.37484031316887
34340.9328.84489176785712.055108232143
35318.8318.1230316687760.676968331224044
36265.7259.9423060216345.75769397836559
37322.7312.58665680027510.1133431997253
38281.6282.496618864764-0.89661886476384
39323.5331.830341404399-8.33034140439935
40312.6311.5996539269881.00034607301177
41310.8297.78587841226613.0141215877335
42262.8256.7435151147346.05648488526613
43273.8272.8284626550540.971537344946015
44320292.55280592501927.4471940749815
45310.3304.4461288028835.85387119711742
46342.2336.8497959970335.35020400296718
47320.1324.879741237325-4.77974123732481
48265.6265.4508209295560.149179070443747
49327320.1754961425756.82450385742518
50300.7292.9979124151947.70208758480634
51346.4342.3316349548294.06836504517085
52317.3317.940298608661-0.640298608661439
53326.2306.62291241519419.5770875848063
54270.7263.9162895701586.78371042984159
55278.2280.417301997354-2.21730199735419
56324.6300.55771015419424.0422898458057
57321.8315.3634872401886.43651275981197
58343.5344.438635339333-0.938635339332994
59354338.7095538827615.2904461172401
60278.2274.7039198193593.49608018064089
61330.2329.0125301455021.187469854498
62307.3301.4188815312455.88111846875488
63375.9357.82570714776718.0742928522332
64335.3330.9379814803454.36201851965484
65339.3317.95633573937521.3436642606253
66280.3273.5854533468376.71454665316315
67293.7292.1667902084111.53320979158906
68341.2313.97145791275427.2285420872462
69345.1327.94510522499617.1548947750039
70368.7358.68451287164410.0154871283563
71369.4352.53936652819516.8606334718051
72288.4284.3730835960384.02691640396243
73341338.2656290353052.73437096469521
74319.1312.3362399685516.76376003144944
75374.2365.8306113769438.36938862305736
76344.5343.1035345782781.39646542172241
77337.3328.0415644029299.25843559707116
78281282.006422462888-1.00642246288836
79282.2300.171694437587-17.9716944375868
80321321.97636214193-0.976362141929565
81325.4336.366074341048-10.9660743410476
82366.3369.185806422073-2.88580642207345
83380.3370.11376315551110.1862368444891
84300.7298.2028962414732.4971037585274
85359.3355.4239607757453.87603922425493
86327.6329.494571708991-1.89457170899085
87383.6382.9889431173830.611056882617091
88352.4357.349412110588-4.94941211058831
89329.4340.207117500861-10.8071175008613
90294.5297.500494655826-3.00049465582602
91333.5323.15493459428610.3450654057137
92334.3335.806174787365-1.5061747873646
93358355.1886656289912.81133437100946
94396.1395.4975656737780.602434326221781
95387389.768484217205-2.76848421720514
96307.2314.529098208162-7.32909820816158
97363.9372.582292516185-8.68229251618542
98344.7351.645682091939-6.94568209193909
99397.6406.388248160958-8.78824816095807
100376.8380.748717154163-3.94871715416343
101337.1360.277903449431-23.1779034494312
102299.3314.658826396266-15.3588263962663
103323.1335.736552579094-12.6365525790943
104329.1352.548441640929-23.4484416409292
105347368.60241338755-21.6024133875499
1064624623.8838832323862e-15
107436.5419.40876256391517.0912374360848
108360.4342.50511700736917.894882992631
109415.5400.55831131539314.9416886846072
110382.1373.7967924748878.30320752511276
111432.2426.0429692226526.15703077734764
112424.3410.80506038774913.4949396122509
113386.7387.421792474887-0.721792474887278
114354.5342.63484519547411.8651548045263
115375.8366.2089606995569.59103930044433
116368377.195941345131-9.1959413451314
117402.4399.4908863948872.90911360511305
118426.5436.471267344669-9.97126734466937
119433.3437.815288964982-4.51528896498242
120338.5347.18150214154-8.68150214153956
121416.8414.3881239608282.41187603917217
122381.1389.290864667825-8.19086466782492
123445.7451.10653381373-5.40653381373016
124412.4416.313575295671-3.91357529567105
125394402.915864667825-8.91586466782494
126348.2353.136138745904-4.93613874590352
127380.1378.3745137974881.72548620251191
128373.7392.690013538069-18.9900135380691
129393.6406.663660850311-13.0636608503114
130434.2452.797469311358-18.5974693113584
131430.7449.980842062915-19.2808420629149
132344.5359.763120126348-15.2631201263476
133411.9424.473352624382-12.573352624382
134370.5388.142341385736-17.6423413857363
135437.3450.790140305393-13.4901403053928
136411.3426.398803959225-15.0988039592251
137385.5403.847665820115-18.3476658201146
138341.3355.31613455882-14.0161345588201
139384.2385.963353139788-1.7633531397883
140373.2397.36639867224-24.1663986722396
141415.8423.405927703876-7.60592770387606
142448.6458.30598421928-9.70598421928026
143454.3459.233940952718-4.93394095271766
144350.3364.023440373643-13.7234403736425
145419.1431.646127079806-12.5461270798065
146398403.636413578674-5.63641357867399
147456.1465.868147611455-9.76814761145483
148430.1433.155513527774-3.055513527774
149399.8411.436505162415-11.6365051624148
150362.7364.985298335499-2.28529833549861
151384.9388.143348952705-3.24334895270493
152385.3404.123108240788-18.8231082407885
153432.3432.2429617068030.0570382931967554
154468.9467.1430182222071.75698177779256
155442.7456.005093236251-13.3050932362508
156370.2372.86047437657-2.66047437656971
157439.4441.731355743361-2.33135574336064
158393.9404.568214730964-10.6682147309637
159468.7471.376662519377-2.67666251937675
160438.8436.9997688881931.80023111180674
161430.1433.171550658487-3.0715506584873
162366.3368.829553695918-2.52955369591785
163391391.987604313124-0.987604313124178
164380.9402.558520071824-21.6585200718242
165431.4433.590827745969-2.19082774596857
166465.4469.323014035124-3.92301403512405
167471.5470.2509707685611.24902923143856
168387.5382.1135732663725.3864267336275
169446.4447.239870651283-0.839870651282532
170421.5415.4855731682696.01442683173091
171504.8496.0241622235798.77583777642112
172492.1458.73481438426633.3651856157342
173421.3423.28566475201-1.98566475200986
174396.7383.07543122822913.6245687717714
175428412.05839026169415.9416097383059
176421.9425.125695341648-3.22569534164808
177465.6454.07767858141411.5223214185859
178525.8503.95607102434221.843928975658
179499.9486.16110784837513.7388921516252
180435.3409.67352717870425.6264728212957
181479.5468.97491614735510.5250838526449
182473447.20617594935725.7938240506426
183554.4520.25559704090534.1444029590946
184489.6474.22888657720315.3711134227965
185462.2454.1741377593478.02586224065313
186420.3407.72293093243112.5770690675693


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
180.01154177201701480.02308354403402970.988458227982985
190.002939459066903210.005878918133806430.997060540933097
200.0009886684605658140.001977336921131630.999011331539434
210.0003759149897277290.0007518299794554580.999624085010272
228.41380379049754e-050.0001682760758099510.999915861962095
231.64806922023281e-053.29613844046562e-050.999983519307798
246.37602709202849e-061.2752054184057e-050.999993623972908
251.85970140714245e-063.71940281428491e-060.999998140298593
263.91742712762915e-067.8348542552583e-060.999996082572872
271.49004024138338e-062.98008048276677e-060.999998509959759
283.75370407704599e-077.50740815409197e-070.999999624629592
298.02542235370713e-081.60508447074143e-070.999999919745777
302.39196064452785e-084.78392128905571e-080.999999976080394
316.84023583690318e-091.36804716738064e-080.999999993159764
324.73155686291205e-099.4631137258241e-090.999999995268443
338.3044967809025e-091.6608993561805e-080.999999991695503
342.01032746375371e-094.02065492750742e-090.999999997989673
356.07144735961084e-101.21428947192217e-090.999999999392855
362.34764311435118e-104.69528622870237e-100.999999999765236
378.80132969890297e-111.76026593978059e-100.999999999911987
381.19056239752013e-102.38112479504026e-100.999999999880944
396.44570998374905e-101.28914199674981e-090.99999999935543
401.80955498112548e-103.61910996225097e-100.999999999819045
415.14852912589011e-111.02970582517802e-100.999999999948515
423.13787757038802e-116.27575514077603e-110.999999999968621
438.17335635694335e-121.63467127138867e-110.999999999991827
443.98665041802543e-127.97330083605087e-120.999999999996013
452.30531757879219e-124.61063515758437e-120.999999999997695
462.27809043256419e-124.55618086512838e-120.999999999997722
478.88694141330038e-131.77738828266008e-120.999999999999111
484.1674006749575e-138.33480134991501e-130.999999999999583
491.14815009001251e-132.29630018002502e-130.999999999999885
504.72881160856874e-149.45762321713748e-140.999999999999953
511.39030828657127e-142.78061657314254e-140.999999999999986
525.72417177198805e-151.14483435439761e-140.999999999999994
533.70257526576955e-157.40515053153909e-150.999999999999996
542.96962155945202e-155.93924311890403e-150.999999999999997
551.28394774167804e-152.56789548335609e-150.999999999999999
561.75329449085286e-153.50658898170571e-150.999999999999998
572.65314672898131e-145.30629345796262e-140.999999999999973
581.01245787509608e-132.02491575019216e-130.999999999999899
593.98275659680681e-147.96551319361363e-140.99999999999996
601.3651527080515e-142.73030541610301e-140.999999999999986
611.5218500971959e-143.04370019439179e-140.999999999999985
629.28863128726393e-151.85772625745279e-140.99999999999999
638.08956700039195e-151.61791340007839e-140.999999999999992
643.72912247521907e-157.45824495043814e-150.999999999999996
653.49502492270536e-156.99004984541071e-150.999999999999997
661.22718729968773e-152.45437459937547e-150.999999999999999
671.7481426460481e-153.4962852920962e-150.999999999999998
688.8355051201432e-141.76710102402864e-130.999999999999912
691.56651476198597e-133.13302952397195e-130.999999999999843
704.31859655019541e-138.63719310039081e-130.999999999999568
714.83182400007517e-139.66364800015034e-130.999999999999517
722.04852134499339e-134.09704268998678e-130.999999999999795
731.68162156346977e-133.36324312693954e-130.999999999999832
742.15349613295151e-134.30699226590302e-130.999999999999785
753.50346136099156e-137.00692272198312e-130.99999999999965
768.72187528544341e-131.74437505708868e-120.999999999999128
771.84701477735864e-113.69402955471728e-110.99999999998153
781.57167413852305e-113.14334827704611e-110.999999999984283
794.63313055480943e-099.26626110961886e-090.99999999536687
806.73191911516217e-061.34638382303243e-050.999993268080885
810.0001358170339335340.0002716340678670680.999864182966066
820.000313271447829310.000626542895658620.99968672855217
830.0006041390772897230.001208278154579450.99939586092271
840.0005040467622845410.001008093524569080.999495953237715
850.0005807275313602590.001161455062720520.99941927246864
860.0009762847552177790.001952569510435560.999023715244782
870.001194772265577650.00238954453115530.998805227734422
880.001095446367932090.002190892735864180.998904553632068
890.005478201291022390.01095640258204480.994521798708978
900.005134454839277360.01026890967855470.994865545160723
910.005957358069044930.01191471613808990.994042641930955
920.03003070553407580.06006141106815160.969969294465924
930.04226387756785090.08452775513570180.95773612243215
940.06201264005090580.1240252801018120.937987359949094
950.07918015558456640.1583603111691330.920819844415434
960.07654053947847030.1530810789569410.92345946052153
970.08476464648567720.1695292929713540.915235353514323
980.08091629154856680.1618325830971340.919083708451433
990.07792827766986210.1558565553397240.922071722330138
1000.06782851047163840.1356570209432770.932171489528362
1010.1458241298977110.2916482597954220.854175870102289
1020.1496015693644630.2992031387289260.850398430635537
1030.1369534880588620.2739069761177230.863046511941138
1040.3002087669771450.6004175339542910.699791233022855
1050.3341313949470310.6682627898940620.665868605052969
1060.2933676914513410.5867353829026830.706632308548659
1070.6034997044192080.7930005911615850.396500295580792
1080.755977304847380.488045390305240.24402269515262
1090.892993448592430.2140131028151410.10700655140757
1100.9259593562512440.1480812874975120.074040643748756
1110.976666797107860.04666640578427850.0233332028921392
1120.9865757016810120.02684859663797660.0134242983189883
1130.9922156521414350.01556869571713070.00778434785856537
1140.99746541835180.005069163296401750.00253458164820088
1150.9986222244427390.002755551114523070.00137777555726153
1160.9997548087939420.0004903824121158150.000245191206057908
1170.9999492962032810.0001014075934376365.07037967188182e-05
1180.999962645160377.47096792584925e-053.73548396292463e-05
1190.9999795362393344.09275213313677e-052.04637606656839e-05
1200.999979196920694.16061586181105e-052.08030793090553e-05
1210.9999989459238242.10815235191308e-061.05407617595654e-06
1220.9999984675664293.0648671422762e-061.5324335711381e-06
1230.9999985900299242.81994015157492e-061.40997007578746e-06
1240.9999984186776013.16264479787431e-061.58132239893716e-06
1250.9999989976674682.00466506487054e-061.00233253243527e-06
1260.9999990209643771.95807124577532e-069.7903562288766e-07
1270.9999993393891121.32122177589362e-066.6061088794681e-07
1280.9999997458553785.08289243711268e-072.54144621855634e-07
1290.9999997265726615.46854677459003e-072.73427338729501e-07
1300.9999996726277726.5474445662492e-073.2737222831246e-07
1310.9999996222868797.5542624192508e-073.7771312096254e-07
1320.9999993979810641.20403787191137e-066.02018935955683e-07
1330.9999990930206851.81395862980935e-069.06979314904673e-07
1340.9999984725607133.05487857319203e-061.52743928659601e-06
1350.999997455060655.0898787000073e-062.54493935000365e-06
1360.9999983765677043.24686459175462e-061.62343229587731e-06
1370.9999973603244845.27935103169287e-062.63967551584643e-06
1380.999995054622259.89075549941745e-064.94537774970873e-06
1390.999990206572731.9586854538394e-059.793427269197e-06
1400.999987568860022.48622799608513e-051.24311399804257e-05
1410.9999743784183465.12431633072378e-052.56215816536189e-05
1420.9999493841751530.0001012316496941975.06158248470987e-05
1430.9999051219621640.0001897560756728319.48780378364156e-05
1440.9998829895926530.0002340208146949420.000117010407347471
1450.9997807841362650.0004384317274704170.000219215863735208
1460.9995784538704350.0008430922591305230.000421546129565261
1470.9992924405234640.001415118953072270.000707559476536133
1480.9989514192202050.002097161559590620.00104858077979531
1490.998234493445140.003531013109718680.00176550655485934
1500.997053377543820.005893244912359720.00294662245617986
1510.99488707545720.01022584908560130.00511292454280066
1520.9921304721018280.01573905579634320.00786952789817162
1530.9873036422013950.02539271559720930.0126963577986047
1540.982379208679740.03524158264051920.0176207913202596
1550.9758140595461820.04837188090763540.0241859404538177
1560.9628008476737420.07439830465251640.0371991523262582
1570.9437893733863690.1124212532272630.0562106266136315
1580.9396765540988880.1206468918022250.0603234459011125
1590.90820855430380.18358289139240.0917914456961998
1600.8769107186509740.2461785626980520.123089281349026
1610.8478949873345480.3042100253309030.152105012665452
1620.7939674920398260.4120650159203490.206032507960174
1630.74789414070240.5042117185951990.252105859297599
1640.7020256352659050.595948729468190.297974364734095
1650.6206784284326410.7586431431347180.379321571567359
1660.4924806734053690.9849613468107380.507519326594631
1670.5129600124681990.9740799750636020.487039987531801
1680.3841049877138370.7682099754276740.615895012286163


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level1070.708609271523179NOK
5% type I error level1190.788079470198676NOK
10% type I error level1220.80794701986755NOK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/10wzh01261082312.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/10wzh01261082312.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/1vi191261082312.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/1vi191261082312.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/2zlbw1261082312.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/2zlbw1261082312.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/3vge31261082312.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/3vge31261082312.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/45qcd1261082312.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/45qcd1261082312.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/5i7561261082312.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/5i7561261082312.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/6x8sm1261082312.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/6x8sm1261082312.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/74n5y1261082312.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/74n5y1261082312.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/8e3zy1261082312.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/8e3zy1261082312.ps (open in new window)


http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/95pzq1261082312.png (open in new window)
http://www.freestatistics.org/blog/date/2009/Dec/17/t12610824195fwi2n0lvlyhu03/95pzq1261082312.ps (open in new window)


 
Parameters (Session):
par1 = FALSE ; par2 = 0.0 ; par3 = 1 ; par4 = 1 ; par5 = 12 ; par6 = 3 ; par7 = 0 ; par8 = 2 ; par9 = 1 ;
 
Parameters (R input):
par1 = 1 ; par2 = Include Monthly Dummies ; par3 = Linear Trend ; par4 = 1 ; par5 = 12 ; par6 = 3 ; par7 = 0 ; par8 = 2 ; par9 = 1 ;
 
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