Home » date » 2010 » Nov » 22 »

WS7 t1

*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: Mon, 22 Nov 2010 18:48:49 +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/Nov/22/t1290451644kfausaihvtxowrv.htm/, Retrieved Mon, 22 Nov 2010 19:47:24 +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/Nov/22/t1290451644kfausaihvtxowrv.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 «
24 14 11 12 24 26 25 11 7 8 25 23 17 6 17 8 30 25 18 12 10 8 19 23 18 8 12 9 22 19 16 10 12 7 22 29 20 10 11 4 25 25 16 11 11 11 23 21 18 16 12 7 17 22 17 11 13 7 21 25 23 13 14 12 19 24 30 12 16 10 19 18 23 8 11 10 15 22 18 12 10 8 16 15 15 11 11 8 23 22 12 4 15 4 27 28 21 9 9 9 22 20 15 8 11 8 14 12 20 8 17 7 22 24 31 14 17 11 23 20 27 15 11 9 23 21 34 16 18 11 21 20 21 9 14 13 19 21 31 14 10 8 18 23 19 11 11 8 20 28 16 8 15 9 23 24 20 9 15 6 25 24 21 9 13 9 19 24 22 9 16 9 24 23 17 9 13 6 22 23 24 10 9 6 25 29 25 16 18 16 26 24 26 11 18 5 29 18 25 8 12 7 32 25 17 9 17 9 25 21 32 16 9 6 29 26 33 11 9 6 28 22 13 16 12 5 17 22 32 12 18 12 28 22 25 12 12 7 29 23 29 14 18 10 26 30 22 9 14 9 25 23 18 10 15 8 14 17 17 9 16 5 25 23 20 10 10 8 26 23 15 12 11 8 20 25 20 14 14 10 18 24 33 14 9 6 32 24 29 10 12 8 25 23 23 14 17 7 25 21 26 16 5 4 23 24 18 9 12 8 21 24 20 10 12 8 20 28 11 6 6 4 15 16 28 8 24 20 30 20 26 13 12 8 24 29 22 10 12 8 26 27 17 8 14 6 24 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 time27 seconds
R Server'Sir Ronald Aylmer Fisher' @ 193.190.124.24


Multiple Linear Regression - Estimated Regression Equation
ParentalExpectations[t] = + 6.16887701869768 + 0.0910412769387536ConcernoverMistakes[t] -0.124974617942723Doubtsaboutactions[t] + 0.665424927458418ParentalCriticism[t] + 0.116609399359390PersonalStandards[t] -0.0883713236862746Organization[t] + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)6.168877018697681.7713413.48260.0006480.000324
ConcernoverMistakes0.09104127693875360.0481051.89250.0603070.030154
Doubtsaboutactions-0.1249746179427230.087221-1.43290.1539410.07697
ParentalCriticism0.6654249274584180.0863057.710200
PersonalStandards0.1166093993593900.0632171.84460.0670320.033516
Organization-0.08837132368627460.06186-1.42860.1551640.077582


Multiple Linear Regression - Regression Statistics
Multiple R0.638267527023895
R-squared0.407385436053198
Adjusted R-squared0.388018947035329
F-TEST (value)21.0355855249398
F-TEST (DF numerator)5
F-TEST (DF denominator)153
p-value5.55111512312578e-16
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation2.69537380350115
Sum Squared Residuals1111.55111091184


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
11115.0902933123129-4.0902933123129
2713.2762821036644-6.27628210366435
31713.57912932729233.42087067270766
41011.8143621509940-1.81436215099402
51213.6829990430466-1.68299904304659
61211.03640416150410.963595838495944
71110.10760797970710.892392020292914
81114.3967092422446-3.39670924224459
91210.50419127673221.49580872326780
101311.23934671588581.76065328411421
111414.7179223038925-0.717922303892455
121614.67956394760731.32043605239274
131113.7222505886242-2.72225058862422
141012.1715045424060-2.17150454240604
151112.2210218592443-1.22102185924431
161510.09723029951334.90276970048665
17913.7427769322339-4.74277693223385
181112.4301743557007-1.43017435570071
191712.09237512357594.90762487642411
201715.4757758661841.52422413381600
211113.5674149618832-2.56741496188315
221815.26573166239602.73426833760396
231415.9662771203031-1.96627712030308
241012.6313401159530-2.63134011595297
251111.7051308268035-0.705130826803506
261513.17566927009711.8243307299029
271511.65180377625293.34819622374708
281313.0394634394106-0.0394634394105844
291613.80192303683262.19807696316744
301311.11722307104481.88277692895524
31911.4491376476338-2.44913764763384
321818.0030465092912-0.00304650929119785
331812.27934281409685.72065718590321
341213.6253041781773-1.62530417817728
351713.64006869887073.35993130112927
36912.1591717239839-3.15917172398391
37913.111961986022-4.11196198602199
38128.71813503712163.28186496287841
391816.88849565589101.11150434410898
401212.9523201557008-0.952320155700772
411814.09438334606353.9056166539365
421413.91853243619200.0814675638080462
431512.01149233220022.98850766779985
441610.80162634166455.19837365833548
451013.0626597362727-3.06265973627270
461111.4811050721646-0.481105072164592
471412.87236460085721.12763539914275
48913.0267330822588-4.02673308225883
491213.7654218293621-1.76542182936209
501712.23059341587284.76940658412719
5159.75916045865077-4.75916045865077
521212.3341334798547-0.334133479854686
531211.92114672168500.0788532783150179
5469.41738287861176-3.41738287861176
552422.75758988566561.24241011433443
561212.4705368032406-0.470536803240622
571212.8912569954051-0.891256995405105
581411.56378781139252.43621218860746
5979.13925944888823-2.13925944888823
601311.11082545841781.8891745415822
611213.1699740047662-1.16997400476625
621311.50126103588961.49873896411044
631411.38116887883992.61883112116007
64812.8494881336204-4.84948813362038
65119.339706388994181.66029361100583
66911.7252295593965-2.72522955939653
671113.7592540973606-2.75925409736060
681313.3899451240086-0.389945124008605
69109.362423538313120.637576461686878
701112.6443330715980-1.64433307159803
711212.7642291877397-0.764229187739686
72911.8481211530213-2.84812115302130
731514.61496747936190.385032520638060
741814.90360472330493.09639527669505
751512.10968011419922.89031988580083
761212.8128698183052-0.812869818305165
77139.83483282684423.16516717315581
781413.01436778366060.985632216339413
791011.8416130832527-1.84161308325268
801312.30692740325010.693072596749949
811313.6966402561304-0.696640256130414
821112.0658770888727-1.06587708887274
831312.17585730549650.824142694503452
841614.43847810402931.56152189597069
8589.66985922268198-1.66985922268198
861611.57527374796774.42472625203231
871111.0690549071499-0.0690549071499213
88911.2274987396122-2.22749873961222
891617.7385710036935-1.73857100369345
901211.43345158501360.566548414986438
911411.97115300821352.02884699178646
92810.5416330824799-2.54163308247993
9399.5277606339652-0.527760633965194
941511.71256880885463.28743119114537
951113.4909106406515-2.49091064065145
962117.16035591753023.83964408246983
971413.21990135823160.780098641768431
981815.76250273530262.23749726469742
991211.67503560231570.324964397684325
1001312.66535239002020.33464760997982
1011514.49354787130020.506452128699828
1021211.01200420234710.987995797652922
1031914.43742707877984.56257292122016
1041513.96670060008681.03329939991321
1051112.9368506119609-1.93685061196091
1061110.6791788620760.320821137923995
1071012.335578068881-2.33557806888100
1081314.7733541108617-1.77335411086173
1091514.72454748150580.275452518494184
110129.852826833187972.14717316681203
1111210.96406760856091.03593239143914
1121615.68139237894040.318607621059554
113915.4318202038122-6.43182020381219
1141817.46877729352200.531222706477954
115814.9072071421707-6.90720714217072
1161310.28075076154462.71924923845535
1171714.15024944492192.84975055507809
118910.9875403311856-1.98754033118563
1191513.12858365553021.87141634446984
12089.64377645368698-1.64377645368698
121711.1837282246314-4.18372822463136
1221211.29512720080840.704872799191556
1231414.9779944961403-0.977994496140275
124610.6501536890186-4.65015368901865
125810.0634389095600-2.06343890956002
1261712.35463812153304.64536187846698
127109.640893956506870.359106043493133
1281112.4393523485524-1.43935234855237
1291412.69784114199781.30215885800217
1301113.5695552173331-2.56955521733305
1311315.3246802742953-2.32468027429533
1321211.83411790023910.165882099760948
1331110.30329357188690.69670642811309
13499.35386895969433-0.353868959694334
1351211.98760701961750.0123929803824522
1362014.65320472268025.34679527731984
1371210.62365164919331.37634835080672
1381313.5967191140340-0.596719114033957
1391213.0334917483171-1.03349174831707
1401216.4374760656668-4.43747606566676
141914.5841126764461-5.58411267644606
1421515.4921726464561-0.492172646456068
1432421.47780571288252.52219428711755
14479.86113482063936-2.86113482063936
1451714.51359506736662.48640493263336
1461111.8295717418214-0.829571741821423
1471715.09138922338581.90861077661417
1481112.2042764010189-1.20427640101887
1491212.5068570210313-0.506857021031325
1501414.3909989558550-0.390998955854967
1511114.1913798412456-3.19137984124556
1521612.71955212172133.28044787827867
1532113.73060343172967.26939656827036
1541412.19468581820941.80531418179062
1552016.29670492796213.70329507203789
1561310.94413752033912.05586247966086
1571112.9695013576068-1.96950135760678
1581513.82260201748761.17739798251241
1591917.85329487143431.14670512856569


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
90.5581471178983820.8837057642032360.441852882101618
100.4176223819275730.8352447638551460.582377618072427
110.615513367973810.768973264052380.38448663202619
120.7923856346093050.4152287307813890.207614365390695
130.803498339255660.3930033214886800.196501660744340
140.743119346740850.5137613065182990.256880653259150
150.6613252658852460.6773494682295090.338674734114754
160.6235050260728720.7529899478542570.376494973927128
170.6692033218133340.6615933563733310.330796678186666
180.5895478708673670.8209042582652650.410452129132633
190.6969339357995870.6061321284008260.303066064200413
200.7816884057803880.4366231884392250.218311594219612
210.739238624604440.5215227507911210.260761375395560
220.798861340785030.4022773184299410.201138659214970
230.7540373439285040.4919253121429920.245962656071496
240.7803268067357070.4393463865285870.219673193264293
250.7312663267206980.5374673465586040.268733673279302
260.7078011610683370.5843976778633250.292198838931663
270.6888593794940230.6222812410119530.311140620505977
280.6285093538923630.7429812922152740.371490646107637
290.6007103981804020.7985792036391960.399289601819598
300.5492493657657750.901501268468450.450750634234225
310.6290924349644970.7418151300710060.370907565035503
320.615865464746040.768269070507920.38413453525396
330.681275673295820.637448653408360.31872432670418
340.7262608300304350.5474783399391310.273739169969565
350.7401198721668760.5197602556662480.259880127833124
360.777505517480090.4449889650398190.222494482519910
370.830496574630820.3390068507383610.169503425369181
380.8272742585872680.3454514828254640.172725741412732
390.8151570057223230.3696859885553530.184842994277677
400.786329013564520.4273419728709590.213670986435479
410.8424379812178260.3151240375643480.157562018782174
420.8079055335837130.3841889328325740.192094466416287
430.8203358460147590.3593283079704830.179664153985241
440.8720794533449150.2558410933101710.127920546655086
450.8862167978328330.2275664043343340.113783202167167
460.8626566936755150.2746866126489710.137343306324485
470.8396132533105120.3207734933789760.160386746689488
480.8669832423605750.2660335152788510.133016757639425
490.8466502959590980.3066994080818040.153349704040902
500.895440623239430.2091187535211410.104559376760571
510.9363844114129250.1272311771741510.0636155885870754
520.9203981984319240.1592036031361530.0796018015680763
530.9004019686949350.199196062610130.099598031305065
540.9208374069455030.1583251861089950.0791625930544975
550.9060081300930830.1879837398138340.093991869906917
560.8844949839615590.2310100320768820.115505016038441
570.8628591473554580.2742817052890850.137140852644542
580.8552978921352440.2894042157295120.144702107864756
590.8525686470229410.2948627059541170.147431352977059
600.8347805031455840.3304389937088310.165219496854416
610.8127191047439930.3745617905120140.187280895256007
620.790160485876720.4196790282465610.209839514123280
630.7862877229003910.4274245541992180.213712277099609
640.8618296459686630.2763407080626740.138170354031337
650.8457573026515470.3084853946969060.154242697348453
660.8420311355307180.3159377289385630.157968864469282
670.8417061245389920.3165877509220160.158293875461008
680.8144096335780830.3711807328438330.185590366421917
690.7896277960663120.4207444078673770.210372203933688
700.767400803556090.4651983928878210.232599196443910
710.739420006055760.5211599878884790.260579993944240
720.7421771381084450.5156457237831090.257822861891555
730.7097707865575280.5804584268849440.290229213442472
740.7281455466929560.5437089066140880.271854453307044
750.7357158881843020.5285682236313970.264284111815698
760.7004971950629690.5990056098740620.299502804937031
770.7311506579475260.5376986841049480.268849342052474
780.6976995716739960.6046008566520090.302300428326004
790.672804031872050.65439193625590.32719596812795
800.6339852672169930.7320294655660130.366014732783007
810.5912018250243380.8175963499513240.408798174975662
820.5554180112876050.889163977424790.444581988712395
830.5140592735917980.9718814528164040.485940726408202
840.4826892679748370.9653785359496750.517310732025163
850.4538429369413560.9076858738827110.546157063058645
860.5367236301989140.9265527396021720.463276369801086
870.490720896113040.981441792226080.50927910388696
880.4690317939804760.9380635879609530.530968206019524
890.4467662603421720.8935325206843450.553233739657828
900.4025001964243040.8050003928486070.597499803575696
910.3840327480685180.7680654961370360.615967251931482
920.3754161115664650.750832223132930.624583888433535
930.3324113454573410.6648226909146820.667588654542659
940.3528485874239130.7056971748478250.647151412576087
950.3491333329137210.6982666658274410.650866667086279
960.383188545214710.766377090429420.61681145478529
970.3447328462183570.6894656924367150.655267153781643
980.3232778804218030.6465557608436060.676722119578197
990.2815594739651380.5631189479302760.718440526034862
1000.2424519311738320.4849038623476650.757548068826168
1010.206834051015140.413668102030280.79316594898486
1020.1795647555890860.3591295111781730.820435244410914
1030.2399077329427500.4798154658855010.76009226705725
1040.2091692250695670.4183384501391340.790830774930433
1050.1999080516510710.3998161033021410.80009194834893
1060.1676150114000690.3352300228001370.832384988599931
1070.1601046850519050.3202093701038100.839895314948095
1080.1465836975283130.2931673950566260.853416302471687
1090.1196715331626370.2393430663252730.880328466837363
1100.1117409170863310.2234818341726620.888259082913669
1110.09381494408625410.1876298881725080.906185055913746
1120.08206789210684270.1641357842136850.917932107893157
1130.2222175395925510.4444350791851020.777782460407449
1140.1922811164624680.3845622329249360.807718883537532
1150.4034142809617980.8068285619235950.596585719038202
1160.4019705463769880.8039410927539760.598029453623012
1170.4287901565080280.8575803130160560.571209843491972
1180.3899990751857910.7799981503715820.610000924814209
1190.3536689006059380.7073378012118770.646331099394062
1200.3125419931893610.6250839863787220.687458006810639
1210.3635507810305530.7271015620611050.636449218969447
1220.3386833476355450.677366695271090.661316652364455
1230.2910493319081940.5820986638163870.708950668091806
1240.4072656006978370.8145312013956740.592734399302163
1250.3651729999244240.7303459998488480.634827000075576
1260.4516890549088430.9033781098176870.548310945091157
1270.3960138899124530.7920277798249060.603986110087547
1280.3691453453963040.7382906907926080.630854654603696
1290.3147978309705830.6295956619411660.685202169029417
1300.3653007481637740.7306014963275480.634699251836226
1310.3507259327869630.7014518655739260.649274067213037
1320.2918166545305540.5836333090611080.708183345469446
1330.238339507669760.476679015339520.76166049233024
1340.1894153795253510.3788307590507010.81058462047465
1350.1523600459186780.3047200918373560.847639954081322
1360.2423718239173160.4847436478346320.757628176082684
1370.2303411887183840.4606823774367680.769658811281616
1380.2041528739041720.4083057478083430.795847126095828
1390.184590200825020.369180401650040.81540979917498
1400.2263827296307680.4527654592615350.773617270369232
1410.4303350846003320.8606701692006650.569664915399668
1420.4183420156665560.8366840313331120.581657984333444
1430.3391105212426470.6782210424852940.660889478757353
1440.3144321448091260.6288642896182520.685567855190874
1450.2813344650239080.5626689300478160.718665534976092
1460.2714190593980610.5428381187961230.728580940601939
1470.1951632767171080.3903265534342150.804836723282892
1480.1426781546923990.2853563093847980.8573218453076
1490.0821486403679790.1642972807359580.91785135963202
1500.04394661974549270.08789323949098540.956053380254507


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level00OK
5% type I error level00OK
10% type I error level10.00704225352112676OK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/10kv0e1290451698.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/10kv0e1290451698.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/16lkn1290451698.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/16lkn1290451698.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/26lkn1290451698.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/26lkn1290451698.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/36lkn1290451698.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/36lkn1290451698.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/4hcj81290451698.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/4hcj81290451698.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/5hcj81290451698.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/5hcj81290451698.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/6hcj81290451698.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/6hcj81290451698.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/79l0t1290451698.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/79l0t1290451698.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/8kv0e1290451698.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/8kv0e1290451698.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/9kv0e1290451698.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/22/t1290451644kfausaihvtxowrv/9kv0e1290451698.ps (open in new window)


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