Home » date » 2010 » Dec » 04 »

Multiple Regression NVCA en SPCCS

*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: Sat, 04 Dec 2010 19:35:54 +0000
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81.htm/, Retrieved Sat, 04 Dec 2010 20:35:36 +0100
 
BibTeX entries for LaTeX users:
@Manual{KEY,
    author = {{YOUR NAME}},
    publisher = {Office for Research Development and Education},
    title = {Statistical Computations at FreeStatistics.org, URL http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81.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 «
10 5 4 20 2 2 40 6 5 67 6 5 38 5 2 61 5 2 29 6 4 0 5 7 30 6 6 39 5 4 70 6 1 65 5 4 5 5 1 30 4 5 50 7 5 90 5 5 45 4 4 75 6 3 76 6 5 15 5 5 10 5 5 0 5 4 60 6 4 67 5 2 60 6 1 70 6 2 70 5 3 87 6 3 27 6 2 65 5 2 56 5 6 82 6 5 30 5 3 38 6 5 56 6 5 70 6 2 80 6 4 71 6 3 50 5 1 31 5 2 40 6 5 71 6 2 71 5 2 10 5 5 20 5 5 40 6 2 55 2 2 80 7 3 80 5 1 72 7 2 60 6 2 29 6 4 70 5 2 60 4 5 63 6 2 70 7 2 38 5 2 40 6 5 80 6 2 24 5 5 40 5 4 47 6 1 70 5 1 70 5 2 75 2 5 60 5 5 65 5 3 91 5 2 68 5 5 80 6 2 90 4 5 20 5 2 61 6 3 13 3 6 80 6 3 40 5 4 70 5 2 39 6 3 93 6 5 10 6 5 25 6 3 61 5 2 18 3 5 60 6 2 74 6 3 35 5 1 0 5 5 71 5 2 100 6 1 64 6 5 50 6 2 40 5 2 35 4 4 60 5 4 70 7 2 55 3 4 65 6 2 30 6 2 25 2 1 80 7 4 26 5 6 78 6 4 10 5 7 70 4 1 0 3 2 65 6 1 80 6 2 60 5 1 67 6 5 49 6 3 70 5 2 66 6 3 65 4 3 65 6 5 40 6 1 40 5 2 20 7 2 90 6 5 48 6 2 25 6 1 35 5 2 40 6 5 77 5 2 70 3 5 82 5 1 80 5 2 52 3 5 71 5 4 70 5 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 time6 seconds
R Server'Sir Ronald Aylmer Fisher' @ 193.190.124.24
R Framework
error message
The field 'Names of X columns' contains a hard return which cannot be interpreted.
Please, resubmit your request without hard returns in the 'Names of X columns'.


Multiple Linear Regression - Estimated Regression Equation
Talk[t] = + 34.200144640016 + 5.72914103472968Hands[t] -3.20162175385841`Anxiety `[t] + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)34.20014464001610.5586053.23910.0014890.000745
Hands5.729141034729681.7838143.21170.0016280.000814
`Anxiety `-3.201621753858411.206926-2.65270.0088810.00444


Multiple Linear Regression - Regression Statistics
Multiple R0.336414700021497
R-squared0.113174850390554
Adjusted R-squared0.100857834423756
F-TEST (value)9.18849587397072
F-TEST (DF numerator)2
F-TEST (DF denominator)144
p-value0.000175523819369916
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation22.6677401037284
Sum Squared Residuals73991.0075630657


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
11050.0393627982308-40.0393627982308
22039.2551832017585-19.2551832017585
34052.566882079102-12.5668820791020
46752.56688207910214.4331179208980
53856.4426063059476-18.4426063059476
66156.44260630594764.55739369405244
72955.7685038329604-26.7685038329604
8040.4344975366555-40.4344975366555
93049.3652603252436-19.3652603252436
103950.0393627982307-11.0393627982307
117065.37336909453564.62663090546436
126550.039362798230714.9606372017693
13559.644228059806-54.644228059806
143041.1086000096427-11.1086000096427
155058.2960231138317-8.2960231138317
169046.837741044372343.1622589556277
174544.31022176350110.689778236498927
187558.970125586818816.0298744131812
197652.56688207910223.433117920898
201546.8377410443724-31.8377410443723
211046.8377410443723-36.8377410443723
22050.0393627982307-50.0393627982307
236055.76850383296044.23149616703957
246756.442606305947610.5573936940524
256065.3733690945356-5.37336909453564
267062.17174734067727.82825265932276
277053.240984552089216.7590154479108
288758.970125586818828.0298744131812
292762.1717473406772-35.1717473406772
306556.44260630594768.55739369405244
315643.636119290513912.3638807094861
328252.56688207910229.433117920898
333053.2409845520892-23.2409845520892
343852.566882079102-14.5668820791020
355652.5668820791023.43311792089798
367062.17174734067727.82825265932276
378055.768503832960424.2314961670396
387158.970125586818812.0298744131812
395059.644228059806-9.64422805980597
403156.4426063059476-25.4426063059476
414052.566882079102-12.5668820791020
427162.17174734067728.82825265932276
437156.442606305947614.5573936940524
441046.8377410443723-36.8377410443723
452046.8377410443723-26.8377410443723
464062.1717473406772-22.1717473406772
475539.255183201758515.7448167982415
488064.699266621548515.3007333784515
498059.64422805980620.3557719401940
507267.90088837540694.09911162459309
516062.1717473406772-2.17174734067724
522955.7685038329604-26.7685038329604
537056.442606305947613.5573936940524
546041.108600009642718.8913999903573
556362.17174734067720.828252659322764
567067.90088837540692.09911162459309
573856.4426063059476-18.4426063059476
584052.566882079102-12.5668820791020
598062.171747340677217.8282526593228
602446.8377410443723-22.8377410443723
614050.0393627982307-10.0393627982307
624765.3733690945356-18.3733690945356
637059.64422805980610.3557719401940
647056.442606305947613.5573936940524
657529.650317940183345.3496820598167
666046.837741044372313.1622589556277
676553.240984552089211.7590154479108
689156.442606305947634.5573936940524
696846.837741044372321.1622589556277
708062.171747340677217.8282526593228
719041.108600009642748.8913999903573
722056.4426063059476-36.4426063059476
736158.97012558681882.02987441318117
741332.1778372210546-19.1778372210546
758058.970125586818821.0298744131812
764050.0393627982307-10.0393627982307
777056.442606305947613.5573936940524
783958.9701255868188-19.9701255868188
799352.56688207910240.433117920898
801052.566882079102-42.566882079102
812558.9701255868188-33.9701255868188
826156.44260630594764.55739369405244
831835.379458974913-17.379458974913
846062.1717473406772-2.17174734067724
857458.970125586818815.0298744131812
863559.644228059806-24.6442280598060
87046.8377410443723-46.8377410443723
887156.442606305947614.5573936940524
8910065.373369094535634.6266309054644
906452.56688207910211.4331179208980
915062.1717473406772-12.1717473406772
924056.4426063059476-16.4426063059476
933544.3102217635011-9.31022176350107
946050.03936279823079.96063720176925
957067.90088837540692.09911162459309
965538.581080728771416.4189192712286
976562.17174734067722.82825265932276
983062.1717473406772-32.1717473406772
992542.4568049556169-17.4568049556169
1008061.497644867690118.5023551323099
1012643.6361192905139-17.6361192905139
1027855.768503832960422.2314961670396
1031040.4344975366555-30.4344975366555
1047053.915087025076316.0849129749237
105044.9843242364882-44.9843242364882
1066565.3733690945356-0.373369094535645
1078062.171747340677217.8282526593228
1086059.6442280598060.355771940194033
1096752.56688207910214.4331179208980
1104958.9701255868188-9.97012558681883
1117056.442606305947613.5573936940524
1126658.97012558681887.02987441318117
1136547.511843517359517.4881564826405
1146552.56688207910212.4331179208980
1154065.3733690945356-25.3733690945356
1164056.4426063059476-16.4426063059476
1172067.9008883754069-47.9008883754069
1189052.56688207910237.433117920898
1194862.1717473406772-14.1717473406772
1202565.3733690945356-40.3733690945356
1213556.4426063059476-21.4426063059476
1224052.566882079102-12.5668820791020
1237756.442606305947620.5573936940524
1247035.37945897491334.620541025087
1258259.64422805980622.3557719401940
1268056.442606305947623.5573936940524
1275235.37945897491316.620541025087
1287150.039362798230820.9606372017692
1297056.442606305947613.5573936940524
1305052.566882079102-2.56688207910202
1317252.56688207910219.433117920898
1328058.970125586818821.0298744131812
1339165.373369094535625.6266309054644
1341839.2551832017585-21.2551832017585
1357047.511843517359522.4881564826405
1367653.915087025076322.0849129749237
1376562.17174734067722.82825265932276
1383562.1717473406772-27.1717473406772
1396262.1717473406772-0.171747340677236
1407662.171747340677213.8282526593228
1415052.566882079102-2.56688207910202
1426855.768503832960412.2314961670396
1438056.442606305947623.5573936940524
1449061.497644867690128.5023551323099
1457946.837741044372332.1622589556277
1463041.1086000096427-11.1086000096427
1476046.837741044372313.1622589556277


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
60.626260819551590.7474783608968190.373739180448409
70.5582015348151350.883596930369730.441798465184865
80.4645122492490460.9290244984980920.535487750750954
90.3399250160256620.6798500320513240.660074983974338
100.2428840933587460.4857681867174930.757115906641254
110.1595339529506020.3190679059012050.840466047049398
120.2569547129481850.513909425896370.743045287051815
130.6172752436181710.7654495127636570.382724756381829
140.5454093588324040.9091812823351920.454590641167596
150.4576702959625030.9153405919250060.542329704037497
160.810010576524290.3799788469514210.189989423475710
170.7682460899284630.4635078201430730.231753910071537
180.7677046216952440.4645907566095120.232295378304756
190.7865308028589730.4269383942820550.213469197141027
200.7932596633485070.4134806733029860.206740336651493
210.8171799556068890.3656400887862230.182820044393111
220.8934486140215840.2131027719568330.106551385978416
230.8665666077938970.2668667844122050.133433392206103
240.8536315912537810.2927368174924380.146368408746219
250.814018600692730.3719627986145380.185981399307269
260.7780459187754940.4439081624490120.221954081224506
270.7812761689925870.4374476620148250.218723831007413
280.8074120932914750.385175813417050.192587906708525
290.8524322430244250.2951355139511510.147567756975575
300.8294694310273830.3410611379452340.170530568972617
310.8217959112239650.3564081775520700.178204088776035
320.8503439875669760.2993120248660480.149656012433024
330.8374393835798130.3251212328403750.162560616420187
340.8124654053264180.3750691893471630.187534594673582
350.7743855223463590.4512289553072820.225614477653641
360.7370237885529550.525952422894090.262976211447045
370.7448994101651220.5102011796697560.255100589834878
380.711801695656140.5763966086877190.288198304343859
390.6672630221979640.6654739556040730.332736977802036
400.660105078797530.679789842404940.33989492120247
410.6242045199455680.7515909601088630.375795480054432
420.5806441866279510.8387116267440980.419355813372049
430.565905034717970.868189930564060.43409496528203
440.617291768537510.765416462924980.38270823146249
450.615758365408580.768483269182840.38424163459142
460.6165807546636920.7668384906726150.383419245336308
470.6586521489154740.6826957021690530.341347851084526
480.6289401618300540.7421196763398920.371059838169946
490.6250037314410610.7499925371178780.374996268558939
500.5766245928782140.8467508142435720.423375407121786
510.5272297735263890.9455404529472220.472770226473611
520.5421245980674770.9157508038650460.457875401932523
530.5155049472555140.9689901054889730.484495052744486
540.529313172792490.941373654415020.47068682720751
550.4797399897410360.9594799794820720.520260010258964
560.4306939649555520.8613879299111030.569306035044449
570.4104625897706640.8209251795413290.589537410229336
580.3763812280608640.7527624561217280.623618771939136
590.3587675610800390.7175351221600770.641232438919961
600.3530715838662050.706143167732410.646928416133795
610.3165058859353830.6330117718707660.683494114064617
620.3049172234369450.609834446873890.695082776563055
630.2739415205208990.5478830410417980.726058479479101
640.2518528525707490.5037057051414970.748147147429251
650.4171996497537280.8343992995074560.582800350246272
660.3903650058542920.7807300117085840.609634994145708
670.3581640142845450.7163280285690910.641835985715455
680.4190989788588890.8381979577177780.580901021141111
690.4152954075455020.8305908150910040.584704592454498
700.3972980744841930.7945961489683860.602701925515807
710.5645434130646780.8709131738706440.435456586935322
720.6364416959276220.7271166081447560.363558304072378
730.5914613948583950.817077210283210.408538605141605
740.5801968645805780.8396062708388440.419803135419422
750.5726217558596840.8547564882806320.427378244140316
760.5355422252531310.9289155494937370.464457774746869
770.5041417989087330.9917164021825330.495858201091267
780.4940472554825590.9880945109651190.505952744517441
790.5908396254298060.8183207491403890.409160374570194
800.7092642325956660.5814715348086690.290735767404335
810.763032392156090.473935215687820.23696760784391
820.7255249472173390.5489501055653220.274475052782661
830.7135487037022370.5729025925955260.286451296297763
840.6716256298081350.656748740383730.328374370191865
850.6444298397362240.7111403205275510.355570160263776
860.6520782411245930.6958435177508130.347921758875407
870.8076835665933290.3846328668133430.192316433406671
880.7863822080351780.4272355839296430.213617791964822
890.8363607044734740.3272785910530530.163639295526526
900.810176431073190.3796471378536210.189823568926810
910.7860588913865360.4278822172269290.213941108613464
920.7701466737565490.4597066524869030.229853326243451
930.7443777413577080.5112445172845840.255622258642292
940.7077721955227550.584455608954490.292227804477245
950.6632067269705790.6735865460588420.336793273029421
960.6334181961011970.7331636077976060.366581803898803
970.5850689131763610.8298621736472780.414931086823639
980.6421280813032670.7157438373934660.357871918696733
990.6230784284002020.7538431431995950.376921571599798
1000.5981054447688310.8037891104623380.401894555231169
1010.6105851886495690.7788296227008610.389414811350431
1020.5953472567352130.8093054865295740.404652743264787
1030.7313031775156520.5373936449686960.268696822484348
1040.7148630062843950.5702739874312110.285136993715605
1050.8722664740893250.255467051821350.127733525910675
1060.8419509380504550.3160981238990890.158049061949545
1070.8325958736762850.3348082526474290.167404126323715
1080.7954139709638880.4091720580722230.204586029036112
1090.759781864888560.4804362702228810.240218135111440
1100.7295138236669430.5409723526661130.270486176333057
1110.6949388919638870.6101222160722250.305061108036113
1120.6451763655911230.7096472688177550.354823634408877
1130.6049842728226860.7900314543546290.395015727177314
1140.5530307551133920.8939384897732160.446969244886608
1150.5515159640167050.896968071966590.448484035983295
1160.5361535344368920.9276929311262160.463846465563108
1170.7567038445493450.486592310901310.243296155450655
1180.7880680028676140.4238639942647720.211931997132386
1190.7761360925806350.4477278148387310.223863907419365
1200.9198016216293310.1603967567413380.080198378370669
1210.9513643957708670.09727120845826630.0486356042291331
1220.9599324501645640.08013509967087240.0400675498354362
1230.9475023264000890.1049953471998220.0524976735999109
1240.9620233394143320.07595332117133540.0379766605856677
1250.9520056037691730.09598879246165320.0479943962308266
1260.9428692920673690.1142614158652620.0571307079326311
1270.9284114481040160.1431771037919670.0715885518959837
1280.9112601932381570.1774796135236860.088739806761843
1290.8767407414984040.2465185170031920.123259258501596
1300.8560532941045740.2878934117908520.143946705895426
1310.8085190488418970.3829619023162070.191480951158103
1320.757494598677450.48501080264510.24250540132255
1330.7304643819888720.5390712360222550.269535618011128
1340.7712862419092310.4574275161815380.228713758090769
1350.7129202329413420.5741595341173160.287079767058658
1360.7012786266094140.5974427467811720.298721373390586
1370.5955550182008870.8088899635982260.404444981799113
1380.8107841363565720.3784317272868560.189215863643428
1390.7961191301946660.4077617396106680.203880869805334
1400.7090376508533360.5819246982933290.290962349146664
1410.6880067320331950.623986535933610.311993267966805


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 level40.0294117647058824OK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/10oxj31291491344.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/10oxj31291491344.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/1pm1w1291491343.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/1pm1w1291491343.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/2pm1w1291491343.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/2pm1w1291491343.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/30d0z1291491343.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/30d0z1291491343.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/40d0z1291491343.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/40d0z1291491343.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/50d0z1291491343.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/50d0z1291491343.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/6s4zk1291491343.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/6s4zk1291491343.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/7vo1i1291491344.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/7vo1i1291491344.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/8vo1i1291491344.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/8vo1i1291491344.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/9vo1i1291491344.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/04/t12914913364s3e3i06m6awk81/9vo1i1291491344.ps (open in new window)


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





Copyright

Creative Commons License

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

Software written by Ed van Stee & Patrick Wessa


Disclaimer

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


Privacy Policy

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

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

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

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

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

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

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

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

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


FreeStatistics.org is powered by