Home » date » 2010 » Nov » 16 »

*The author of this computation has been verified*
R Software Module: /rwasp_multipleregression.wasp (opens new window with default values)
Title produced by software: Multiple Regression
Date of computation: Tue, 16 Nov 2010 08:50:28 +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/16/t1289897347jwqkkjji97euqer.htm/, Retrieved Tue, 16 Nov 2010 09:49:07 +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/16/t1289897347jwqkkjji97euqer.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 «
18 15 15 0 17 3 21 2 22 3 24 12 17 3 25 0 16 12 18 15 21 0 19 10 18 20 20 20 25 2 28 3 19 16 20 4 25 2 20 4 21 0 21 0 23 15 19 9 23 1 20 15 19 5 17 4 19 15 21 4 18 12 18 2 24 4 22 2 20 4 17 8 25 30 24 6 18 6 21 7 13 4 21 17 21 5 16 0 18 3 19 4 22 15 18 0 18 8 20 10 19 4 18 0 20 6 20 11 23 10 17 0 17 0 18 0 22 0 16 0 18 0 14 0 13 7 21 4 25 12 16 6 17 12 22 10 24 9 18 0 18 16 18 2 19 0 15 0 25 1 22 10 15 14 21 12 16 12 23 12 20 5 19 0 20 4 18 3 18 0 20 3 20 0 16 12 18 12 18 15 16 0 23 8 14 6 21 14 13 5 27 10 20 16 22 4 21 0 19 8 22 12 12 6 28 4 21 20 18 0 21 13 19 0 23 0 21 0 21 0 22 10 18 6 15 16 23 6 24 0 18 4 15 9 19 17 17 12 14 3 16 8 22 3 15 0 23 10 24 3 24 0 20 8 9 0 23 4 18 13 20 12 25 16 17 20 21 20 26 14 20 12 21 15 15 9 20 4 20 8 16 0 19 13 22 0 17 21 25 0 19 1 17 16 21 12 12 2
 
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
Perf[t] = + 19.7340138067534 + 0.0412068018674213`Sport `[t] -0.00609760335969976t + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)19.73401380675340.61629332.020500
`Sport `0.04120680186742130.0441380.93360.3520610.17603
t-0.006097603359699760.006422-0.94950.3439210.171961


Multiple Linear Regression - Regression Statistics
Multiple R0.105641315003316
R-squared0.0111600874356298
Adjusted R-squared-0.00238566479127944
F-TEST (value)0.823880966422807
F-TEST (DF numerator)2
F-TEST (DF denominator)146
p-value0.440754840001858
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation3.36177350359944
Sum Squared Residuals1650.02207906748


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
11820.346018231405-2.34601823140502
21519.7218186000340-4.72181860003403
31719.8393414022766-2.8393414022766
42119.79203699704951.20796300295052
52219.82714619555722.1728538044428
62420.19190980900433.80809019099571
71719.8149509888378-2.8149509888378
82519.68523297987585.31476702012417
91620.1736169989252-4.17361699892519
101820.2911398011678-2.29113980116776
112119.66694016979671.33305983020326
121920.0729105851112-1.07291058511125
131820.4788810004258-2.47888100042576
142020.4727833970661-0.472783397066062
152519.72496336009285.27503663990722
162819.76007255860058.2399274413995
171920.2896633795173-1.28966337951728
182019.78908415374850.210915846251477
192519.7005729466545.29942705334602
202019.77688894702910.223111052970877
212119.60596413619971.39403586380026
222119.59986653284001.40013346715996
232320.21187095749172.78812904250834
241919.9585325429274-0.95853254292743
252319.62278052462843.37721947537164
262020.1935781474126-0.193578147412559
271919.7754125253786-0.775412525378647
281719.7281081201515-2.72810812015153
291920.1752853373335-1.17528533733346
302119.71591291343211.28408708656787
311820.0394697250118-2.03946972501180
321819.6213041029779-1.62130410297788
332419.69762010335304.30237989664697
342219.60910889625852.39089110374152
352019.68542489663360.314575103366373
361719.8441545007436-2.84415450074361
372520.74460653846724.25539346153282
382419.74954569028944.25045430971063
391819.7434480869297-1.74344808692967
402119.77855728543741.22144271456261
411319.6488392764754-6.64883927647543
422120.17843009739220.821569902607795
432119.67785087162341.32214912837655
441619.4657192589266-3.46571925892664
451819.5832420611692-1.58324206116921
461919.6183512596769-0.61835125967693
472220.06552847685891.93447152314114
481819.4413288454878-1.44132884548785
491819.7648856570675-1.76488565706752
502019.84120165744270.158798342557342
511919.5878632428784-0.587863242878431
521819.4169384320490-1.41693843204905
532019.65808163989390.341918360106126
542019.85801804587130.141981954128720
552319.81071364064423.18928635935584
561719.3925480186102-2.39254801861025
571719.3864504152505-2.38645041525055
581819.3803528118908-1.38035281189085
592219.37425520853112.62574479146885
601619.3681576051714-3.36815760517145
611819.3620600018117-1.36206000181175
621419.3559623984520-5.35596239845205
631319.6383124081643-6.6383124081643
642119.50859439920231.49140560079767
652519.8321512107825.167848789218
661619.5788127962178-3.57881279621778
671719.8199560040626-2.81995600406260
682219.73144479696812.26855520303194
692419.68414039174094.31585960825906
701819.3071815715744-1.30718157157445
711819.9603927980935-1.96039279809349
721819.3773999685899-1.37739996858989
731919.2888887614954-0.288888761495351
741519.2827911581357-4.28279115813565
752519.31790035664345.68209964335663
762219.68266397009052.31733602990953
771519.8413935742004-4.84139357420045
782119.75288236710591.24711763289409
791619.7467847637462-3.74678476374621
802319.74068716038653.25931283961349
812019.44614194395490.553858056045141
821919.2340103312581-0.234010331258053
832019.39273993536800.607260064631961
841819.3454355301409-1.34543553014092
851819.2157175211790-1.21571752117895
862019.33324032342150.666759676578482
872019.20352231445960.796477685540446
881619.6919063335089-3.69190633350891
891819.6858087301492-1.68580873014921
901819.8033315323918-1.80333153239177
911619.1791319010208-3.17913190102076
922319.50268871260043.49731128739957
931419.4141775055059-5.41417750550588
942119.73773431708561.26226568291445
951319.3607754969191-6.36077549691906
962719.56071190289657.43928809710353
972019.80185511074130.198144889258703
982219.30127588497252.69872411502746
992119.13035107414321.86964892585684
1001919.4539078857228-0.453907885722828
1012219.61263748983282.38736251016719
1021219.3592990752686-7.35929907526859
1032819.27078786817408.72921213182596
1042119.92399909469311.07600090530692
1051819.0937654539850-1.09376545398496
1062119.62335627490171.37664372509826
1071919.0815702472656-0.0815702472655591
1082319.07547264390593.92452735609414
1092119.06937504054621.93062495945384
1102119.06327743718651.93672256281354
1112219.46924785250102.53075214749903
1121819.2983230416716-1.29832304167159
1131519.7042934569861-4.7042934569861
1142319.28612783495223.71387216504781
1152419.03278942038804.96721057961204
1161819.1915190244979-1.19151902449795
1171519.3914554304754-4.39145543047535
1181919.7150122420550-0.715012242055023
1191719.5028806293582-2.50288062935822
1201419.1259218091917-5.12592180919173
1211619.3258582151691-3.32585821516913
1222219.11372660247232.88627339752767
1231518.9840085935104-3.98400859351036
1242319.38997900882493.61002099117512
1252419.09543379239324.90456620760677
1262418.96571578343135.03428421656874
1272019.28927259501090.710727404989066
128918.9535205767119-9.95352057671186
1292319.11225018082183.88774981917815
1301819.4770137942689-1.47701379426894
1312019.42970938904180.57029061095818
1322519.58843899315185.4115610068482
1331719.7471685972618-2.74716859726179
1342119.74107099390211.25892900609791
1352619.48773257933796.51226742066214
1362019.39922137224330.600778627756679
1372119.51674417448591.48325582551411
1381519.2634057599217-4.26340575992166
1392019.05127414722490.948725852775148
1402019.21000375133480.789996248665163
1411618.8742517330358-2.87425173303577
1421919.4038425539525-0.403842553952544
1432218.86205652631643.13794347368363
1441719.7213017621725-2.72130176217252
1452518.84986131959706.15013868040303
1461918.88497051810470.115029481895310
1471719.4969749427563-2.49697494275631
1482119.32605013192691.67394986807308
1491218.907884509893-6.90788450989301


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
60.08130666782912390.1626133356582480.918693332170876
70.462892160762270.925784321524540.53710783923773
80.4413971054081720.8827942108163450.558602894591828
90.7865017588061310.4269964823877370.213498241193869
100.7321926625167960.5356146749664070.267807337483203
110.6388645515622630.7222708968754750.361135448437737
120.5536736871421990.8926526257156020.446326312857801
130.4668925415038440.9337850830076880.533107458496156
140.3813822424089450.762764484817890.618617757591055
150.3672218436154640.7344436872309280.632778156384536
160.4557635211592950.911527042318590.544236478840705
170.4264990057186310.8529980114372620.573500994281369
180.4482773281509790.8965546563019580.551722671849021
190.3977527890908030.7955055781816050.602247210909197
200.4110731759300910.8221463518601820.588926824069909
210.3922787476786330.7845574953572660.607721252321367
220.3609116848638580.7218233697277160.639088315136142
230.3154198955187140.6308397910374270.684580104481286
240.3102643469691220.6205286939382440.689735653030878
250.2635449383032340.5270898766064680.736455061696766
260.2188034180372170.4376068360744340.781196581962783
270.2214153830464120.4428307660928250.778584616953588
280.2838310793118640.5676621586237270.716168920688136
290.2396530874670330.4793061749340650.760346912532967
300.1966967189462810.3933934378925610.80330328105372
310.1773120569907720.3546241139815450.822687943009228
320.1759475055548790.3518950111097580.824052494445121
330.1779282448480570.3558564896961140.822071755151943
340.1473782070437460.2947564140874920.852621792956254
350.1205910839207080.2411821678414170.879408916079292
360.1250190982940200.2500381965880390.87498090170598
370.2035099407337500.4070198814674990.79649005926625
380.2035710295069170.4071420590138340.796428970493083
390.1989030093185340.3978060186370680.801096990681466
400.1651508214974530.3303016429949060.834849178502547
410.3469643148166600.6939286296333190.65303568518334
420.3020591359773520.6041182719547050.697940864022648
430.2614173464682030.5228346929364070.738582653531797
440.2840013474720950.568002694944190.715998652527905
450.253336263169530.506672526339060.74666373683047
460.2150037568434340.4300075136868670.784996243156566
470.1938798048294770.3877596096589540.806120195170523
480.1679140699599440.3358281399198880.832085930040056
490.1443595790259850.2887191580519700.855640420974015
500.1174222020887490.2348444041774990.88257779791125
510.0944802040240320.1889604080480640.905519795975968
520.07754826168422520.1550965233684500.922451738315775
530.06122977202242120.1224595440448420.938770227977579
540.04758734138260820.09517468276521650.952412658617392
550.04939892022527360.09879784045054720.950601079774726
560.04315156004208550.0863031200841710.956848439957914
570.03690360063529650.0738072012705930.963096399364703
580.02865504210197230.05731008420394450.971344957898028
590.02735871446329390.05471742892658790.972641285536706
600.02624646312768830.05249292625537660.973753536872312
610.02002436382077130.04004872764154260.979975636179229
620.02814290245624530.05628580491249060.971857097543755
630.05143929326610930.1028785865322190.94856070673389
640.04523544235069160.09047088470138320.954764557649308
650.07509761651108570.1501952330221710.924902383488914
660.07206526236290470.1441305247258090.927934737637095
670.06325420383224980.1265084076645000.93674579616775
680.05986604027163280.1197320805432660.940133959728367
690.07755455044117730.1551091008823550.922445449558823
700.06254003491652190.1250800698330440.937459965083478
710.05150732032037030.1030146406407410.94849267967963
720.04086574020062250.0817314804012450.959134259799377
730.0316397939790560.0632795879581120.968360206020944
740.03440738862150280.06881477724300560.965592611378497
750.06259566414728310.1251913282945660.937404335852717
760.05780820948427420.1156164189685480.942191790515726
770.06817606375800350.1363521275160070.931823936241996
780.05728510836674740.1145702167334950.942714891633253
790.05686882368005730.1137376473601150.943131176319943
800.05955693753248910.1191138750649780.94044306246751
810.04770662462814270.09541324925628530.952293375371857
820.03713076656407840.07426153312815690.962869233435922
830.02912484565950140.05824969131900280.970875154340499
840.02267717043028660.04535434086057330.977322829569713
850.01743867749465840.03487735498931680.982561322505342
860.01327756892422440.02655513784844870.986722431075776
870.01005661165162880.02011322330325760.989943388348371
880.01003346540629110.02006693081258220.989966534593709
890.007705037617847190.01541007523569440.992294962382153
900.005950943915135590.01190188783027120.994049056084864
910.0056606240500250.011321248100050.994339375949975
920.006044939383345720.01208987876669140.993955060616654
930.009957796369274580.01991559273854920.990042203630725
940.007678266506551120.01535653301310220.992321733493449
950.01810635123592370.03621270247184740.981893648764076
960.04915009185371310.09830018370742620.950849908146287
970.03816165058991970.07632330117983930.96183834941008
980.03411885574227270.06823771148454530.965881144257727
990.02792409561917110.05584819123834220.972075904380829
1000.02124583435247310.04249166870494630.978754165647527
1010.01795485027243700.03590970054487390.982045149727563
1020.0539502489026920.1079004978053840.946049751097308
1030.1588151984455430.3176303968910860.841184801554457
1040.1322827278428710.2645654556857430.867717272157129
1050.1116323553497830.2232647106995670.888367644650217
1060.09175435072277240.1835087014455450.908245649277228
1070.07305882253234810.1461176450646960.926941177467652
1080.07396731981934510.1479346396386900.926032680180655
1090.06095034999997450.1219006999999490.939049650000025
1100.050052394155280.100104788310560.94994760584472
1110.04445455535532840.08890911071065680.955545444644672
1120.03428325732967090.06856651465934180.96571674267033
1130.04168585043756660.08337170087513310.958314149562433
1140.04230743722378390.08461487444756780.957692562776216
1150.0591889074056160.1183778148112320.940811092594384
1160.04509254710989580.09018509421979160.954907452890104
1170.04959591948175820.09919183896351650.950404080518242
1180.03717138121808820.07434276243617650.962828618781912
1190.03220617313328670.06441234626657350.967793826866713
1200.04828432798716720.09656865597433440.951715672012833
1210.05497486530319050.1099497306063810.94502513469681
1220.04453371258273820.08906742516547630.955466287417262
1230.06187041160336770.1237408232067350.938129588396632
1240.05190995643899430.1038199128779890.948090043561006
1250.0544517366125610.1089034732251220.945548263387439
1260.06818197385210.13636394770420.9318180261479
1270.04963624581257910.09927249162515830.95036375418742
1280.4319210336023990.8638420672047970.568078966397601
1290.3797851122812080.7595702245624160.620214887718792
1300.377178783796370.754357567592740.62282121620363
1310.3281559493543230.6563118987086470.671844050645677
1320.3454071481565830.6908142963131650.654592851843417
1330.3617827847165620.7235655694331230.638217215283438
1340.2879927341923610.5759854683847220.712007265807639
1350.4104563960753440.8209127921506870.589543603924656
1360.3255568266456120.6511136532912250.674443173354388
1370.2749342580837970.5498685161675940.725065741916203
1380.3192429787272590.6384859574545180.680757021272741
1390.2324386644469210.4648773288938420.767561335553079
1400.1562463393295390.3124926786590770.843753660670461
1410.2638240199854690.5276480399709390.73617598001453
1420.2071743973510030.4143487947020050.792825602648997
1430.1315639684695490.2631279369390980.868436031530451


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level00OK
5% type I error level150.108695652173913NOK
10% type I error level450.326086956521739NOK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/10c9u81289897416.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/10c9u81289897416.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/1vgdk1289897415.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/1vgdk1289897415.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/2vgdk1289897415.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/2vgdk1289897415.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/3vgdk1289897415.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/3vgdk1289897415.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/457un1289897415.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/457un1289897415.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/557un1289897415.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/557un1289897415.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/657un1289897415.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/657un1289897415.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/7q9e31289897416.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/7q9e31289897416.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/810d51289897416.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/810d51289897416.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/910d51289897416.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/16/t1289897347jwqkkjji97euqer/910d51289897416.ps (open in new window)


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





Copyright

Creative Commons License

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

Software written by Ed van Stee & Patrick Wessa


Disclaimer

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


Privacy Policy

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

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

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

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

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

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

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

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

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


FreeStatistics.org is powered by