Home » date » 2010 » Nov » 30 »

WS7

*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, 30 Nov 2010 16:59: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/30/t1291136305y7zueqkzyi4955e.htm/, Retrieved Tue, 30 Nov 2010 17:58:35 +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/30/t1291136305y7zueqkzyi4955e.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 «
1 24 14 11 12 24 26 1 25 11 7 8 25 23 1 17 6 17 8 30 25 1 18 12 10 8 19 23 1 18 8 12 9 22 19 1 16 10 12 7 22 29 1 20 10 11 4 25 25 1 16 11 11 11 23 21 1 18 16 12 7 17 22 2 17 11 13 7 21 25 2 23 13 14 12 19 24 2 30 12 16 10 19 18 2 23 8 11 10 15 22 2 18 12 10 8 16 15 2 15 11 11 8 23 22 2 12 4 15 4 27 28 2 21 9 9 9 22 20 2 15 8 11 8 14 12 2 20 8 17 7 22 24 3 31 14 17 11 23 20 3 27 15 11 9 23 21 3 34 16 18 11 21 20 3 21 9 14 13 19 21 3 31 14 10 8 18 23 3 19 11 11 8 20 28 3 16 8 15 9 23 24 3 20 9 15 6 25 24 3 21 9 13 9 19 24 3 22 9 16 9 24 23 3 17 9 13 6 22 23 3 24 10 9 6 25 29 3 25 16 18 16 26 24 3 26 11 18 5 29 18 3 25 8 12 7 32 25 3 17 9 17 9 25 21 3 32 16 9 6 29 26 3 33 11 9 6 28 22 3 13 16 12 5 17 22 3 32 12 18 12 28 22 3 25 12 12 7 29 23 3 29 14 18 10 26 30 3 22 9 14 9 25 23 3 18 10 15 8 14 17 3 17 9 16 5 25 23 3 20 10 10 8 26 23 3 15 12 11 8 20 25 3 20 14 14 10 18 24 3 33 14 9 6 32 24 3 29 10 12 8 25 23 3 23 14 17 7 25 21 3 26 16 5 4 23 24 3 18 9 12 8 21 2 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 time10 seconds
R Server'Gwilym Jenkins' @ 72.249.127.135


Multiple Linear Regression - Estimated Regression Equation
PStandards[t] = + 8.7962501281589 -0.351026313258320Week[t] + 0.332860819537130Consern[t] -0.359233719372248Doubts[t] + 0.192857556338692PExpect[t] + 0.0149952339047633PCritisism[t] + 0.386464059692393Organisation[t] + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)8.79625012815892.5899943.39620.0008720.000436
Week-0.3510263132583200.338223-1.03790.3009860.150493
Consern0.3328608195371300.0557155.974400
Doubts-0.3592337193722480.107145-3.35280.001010.000505
PExpect0.1928575563386920.1012961.90390.0588130.029406
PCritisism0.01499523390476330.1288420.11640.9075010.453751
Organisation0.3864640596923930.0731595.282500


Multiple Linear Regression - Regression Statistics
Multiple R0.609523247377143
R-squared0.371518589093177
Adjusted R-squared0.346710112346855
F-TEST (value)14.9754695901778
F-TEST (DF numerator)6
F-TEST (DF denominator)152
p-value2.02726724296554e-13
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation3.40841376090285
Sum Squared Residuals1765.82722355781


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
12423.75405289116510.245947108834937
22523.17381152876811.82618847123193
33025.00859725210404.99140274789605
41921.0631247416520-2.06312474165197
52221.35491372695350.645086273046456
62223.8053747782492-1.80537477824919
72523.35311855957521.64688144042483
82320.22155196061822.77844803938184
91719.6104456832432-2.61044568324321
102122.0749768827249-1.07497688272487
111923.2350440273733-4.23504402737327
121923.9612437702189-4.96124377021892
131523.6497213680241-8.64972136802412
141617.6203859508545-1.62038595085451
152319.87914318580083.12085681419919
162724.42543041068522.57456958931477
172221.45112754361070.548872456389319
181417.0922037469936-3.09220374699363
192224.5362266651154-2.53622666511538
202324.2053917473815-1.20539174738148
212321.71404300371141.28595699628857
222124.6783643235871-3.67836432358706
231922.5108340073573-3.51083400735726
241823.9697953303735-5.96979533037352
252023.1783445088454-3.17834450884536
262322.49803242884070.501967571159322
272523.42525628590271.57474371409734
281923.4173876944767-4.41738769447670
292423.94235712333750.0576428766624917
302221.65449465492150.345505345078505
312525.1726408051087-0.172640805108744
322623.30344935604632.69655064395372
332922.94874684133796.0512531586621
343225.27168072754166.72831927245836
352521.69798246260583.30201753739423
362924.52073286609514.47926713390488
372825.10390604372392.89609395627608
381717.2140984912314-0.21409849123139
392826.23750091529131.76249908470866
402923.06181773066795.93818226933214
412627.5821730276651-1.58217302766507
422523.55664201066011.44335798933988
431419.7250429774189-5.72504297741893
442522.21807209003282.78192790996719
452621.74526119295414.25473880704591
462020.3282753322474-0.328275332247418
471821.4962110683218-3.49621106832178
483224.79913300499207.20086699500804
492525.1267236814656-0.12672368146564
502521.86898831515783.13101168484222
512320.94921913632332.05078086367674
522122.2109524456219-1.21095244562185
532024.0632966040934-4.06329660409343
541516.6497891157883-1.64978911578835
553026.84717160451733.15282839548272
562425.3692244228919-1.36922442289186
572624.34255418347531.6574458165247
582421.82012187094002.17987812905996
592221.45384248860060.546157511399372
601415.8252519300394-1.82525193003939
612422.27955091968191.72044908031812
622423.01316827339020.986831726609842
632423.38268822458440.617311775415574
642420.01758257668293.98241742331714
651918.56452485220720.43547514779281
663126.84918000920984.15081999079023
672226.7045192626381-4.70451926263810
682721.57727864242055.4227213575795
691917.74902867150421.25097132849583
702522.35181314930532.64818685069468
712025.1108710070759-5.11087100707585
722121.5637813025458-0.563781302545751
732727.5717783023730-0.571778302373033
742324.5326861243508-1.53268612435084
752525.8088852628178-0.808885262817832
762022.3566306448581-2.35663064485807
772119.29981089929651.70018910070348
782222.5325440926986-0.532544092698643
792323.0127172928268-0.0127172928268160
802524.21103217139300.788967828606965
812523.46132814967171.53867185032834
821723.8687241667847-6.86872416678469
831921.5517631830704-2.55176318307040
842524.03732849723270.962671502767348
851922.0710378851961-3.07103788519606
862022.8964761436804-2.89647614368043
872622.26143161354973.73856838645031
882320.41892270633682.58107729366322
892724.19930667901662.80069332098336
901720.6591658195465-3.65916581954647
911723.1123592044767-6.11235920447671
921919.8325537603912-0.83255376039119
931719.465714624122-2.46571462412202
942221.83486165357680.165138346423220
952123.1893120424487-2.18931204244867
963228.3965101290263.60348987097397
972124.459655157015-3.45965515701502
982124.142194364357-3.14219436435699
991821.0183995389187-3.01839953891872
1001821.0926729490165-3.09267294901653
1012322.61416746842540.385832531574645
1021920.3904284656099-1.39042846560993
1032020.8139286560790-0.813928656079017
1042122.0547948691766-1.05479486917659
1052023.4975148431207-3.49751484312073
1061718.6777634769777-1.67776347697769
1071820.1117835459183-2.11178354591827
1081920.601762536503-1.60176253650299
1092221.85794946391540.142050536084615
1101518.5415140690785-3.54151406907845
1111418.6075402216834-4.60754022168340
1121826.3791792080809-8.3791792080809
1132421.13829910427582.86170089572419
1143523.405301929767611.5946980702324
1152918.828971331313210.1710286686868
1162121.7013100672859-0.70131006728592
1172520.37013529478694.62986470521306
1182018.26771443879431.73228556120566
1192222.9873511751830-0.987351175183036
1201316.7246645151032-3.72466451510316
1212623.00573087183022.99426912816983
1221716.70330770402660.296692295973389
1232519.89358132958055.10641867041948
1242020.4199056469751-0.419905646975105
1251917.84125463923881.15874536076121
1262122.3850040546944-1.38500405469436
1272220.77488134482801.22511865517205
1282422.38725089573941.61274910426061
1292122.6743308789582-1.67433087895821
1302625.25027633191290.749723668087063
1312420.39196087166623.60803912833382
1321620.0348123142121-4.03481231421209
1332322.06215017415820.937849825841796
1341820.528420548334-2.52842054833400
1351622.1128108119103-6.11281081191028
1362623.88580061030592.11419938969415
1371918.84714454829540.152855451704559
1382116.73897310787394.26102689212608
1392121.9012942661034-0.901294266103412
1402218.35123416531533.64876583468466
1412319.62986933791263.37013066208739
1422924.61218982613324.38781017386684
1432119.14465909995301.85534090004697
1442119.69383279133371.30616720866632
1452321.65791907750891.34208092249111
1462722.7839110875184.216088912482
1472525.2340795034825-0.234079503482477
1482120.77193874242480.228061257575235
1491016.9580950705777-6.95809507057771
1502022.4204524716016-2.42045247160164
1512622.29332476836363.70667523163643
1522423.44532851748390.554671482516143
1532931.4517181559671-2.45171815596705
1541918.90952533907120.0904746609288042
1552421.87916071415712.12083928584293
1561920.5305402222784-1.53054022227839
1572423.19950817453490.800491825465104
1582221.59006955046390.409930449536128
1591723.5965892775799-6.59658927757986


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
100.2987668953450180.5975337906900360.701233104654982
110.2928628180359120.5857256360718230.707137181964088
120.2341140810603440.4682281621206890.765885918939656
130.517728042896950.96454391420610.48227195710305
140.489719894701480.979439789402960.51028010529852
150.6334259894914120.7331480210171760.366574010508588
160.5464103632237410.9071792735525170.453589636776259
170.4985852709318470.9971705418636940.501414729068153
180.480376325144350.960752650288700.51962367485565
190.4016519420046920.8033038840093840.598348057995308
200.5216489561170270.9567020877659460.478351043882973
210.5661607774229260.8676784451541490.433839222577074
220.5017664430357570.9964671139284850.498233556964243
230.4439057855899360.8878115711798710.556094214410064
240.4607503497816930.9215006995633870.539249650218307
250.4104802479364760.8209604958729530.589519752063524
260.3601731619903250.720346323980650.639826838009675
270.333941003157960.667882006315920.66605899684204
280.3214987475074560.6429974950149120.678501252492544
290.2795245986458470.5590491972916940.720475401354153
300.2296420226222370.4592840452444740.770357977377763
310.1918819580687300.3837639161374610.80811804193127
320.2332844391096240.4665688782192480.766715560890376
330.3940103604572780.7880207209145570.605989639542722
340.6476910598066090.7046178803867820.352308940193391
350.6270732249371050.745853550125790.372926775062895
360.688354503873270.6232909922534610.311645496126730
370.6772726944055010.6454546111889980.322727305594499
380.6302051678039260.7395896643921470.369794832196074
390.5959672748489360.8080654503021290.404032725151064
400.6762139815860870.6475720368278260.323786018413913
410.646750419951290.706499160097420.35324958004871
420.6017851294667130.7964297410665730.398214870533287
430.6880238235936580.6239523528126840.311976176406342
440.65709046642460.6858190671508010.342909533575400
450.6798458671476570.6403082657046850.320154132852343
460.631908490000370.7361830199992610.368091509999630
470.6263027034215330.7473945931569330.373697296578467
480.7239180609049440.5521638781901110.276081939095056
490.6833970025457570.6332059949084870.316602997454243
500.667393937488440.6652121250231190.332606062511560
510.6263748026757460.7472503946485080.373625197324254
520.5851905775185280.8296188449629440.414809422481472
530.618555389362170.7628892212756590.381444610637829
540.583257141548690.833485716902620.41674285845131
550.6356015774652870.7287968450694250.364398422534713
560.602253196339770.7954936073204590.397746803660229
570.5615233224007970.8769533551984070.438476677599203
580.5274930917497080.9450138165005830.472506908250292
590.4792401866774940.9584803733549880.520759813322506
600.4419762573436370.8839525146872740.558023742656363
610.4086038096755750.817207619351150.591396190324425
620.3653701822784640.7307403645569280.634629817721536
630.3221854846470860.6443709692941710.677814515352914
640.3555337782272180.7110675564544360.644466221772782
650.3124121432399980.6248242864799960.687587856760002
660.3234457364220260.6468914728440520.676554263577974
670.3863802273594540.7727604547189080.613619772640546
680.4609988065993890.9219976131987780.539001193400611
690.4224431610134770.8448863220269540.577556838986523
700.4078596719740910.8157193439481810.592140328025909
710.4712010330943740.9424020661887470.528798966905626
720.4253583247180320.8507166494360630.574641675281968
730.3837523358769750.7675046717539510.616247664123025
740.3476750700030150.695350140006030.652324929996985
750.3151383857619270.6302767715238530.684861614238073
760.2909155259126830.5818310518253650.709084474087317
770.2681117102486650.536223420497330.731888289751335
780.2319803140909940.4639606281819870.768019685909006
790.2000184280486240.4000368560972480.799981571951376
800.1771562607681990.3543125215363980.8228437392318
810.1659928259620230.3319856519240450.834007174037977
820.2412164462382050.4824328924764090.758783553761795
830.2250203972319710.4500407944639420.774979602768029
840.1931847788020200.3863695576040410.80681522119798
850.1902490783610900.3804981567221810.80975092163891
860.1804294907396490.3608589814792980.819570509260351
870.1914645084361940.3829290168723870.808535491563806
880.1811383208223220.3622766416446450.818861679177678
890.1720343284510830.3440686569021670.827965671548917
900.1732033784272120.3464067568544250.826796621572788
910.2403784288795440.4807568577590890.759621571120455
920.2057086524689820.4114173049379640.794291347531018
930.1853052406363980.3706104812727960.814694759363602
940.1562300688658600.3124601377317190.84376993113414
950.1394893664937430.2789787329874850.860510633506257
960.1456349748461410.2912699496922830.854365025153859
970.1433650047641360.2867300095282720.856634995235864
980.1362770022869130.2725540045738270.863722997713087
990.1257313932111470.2514627864222940.874268606788853
1000.1175628916646970.2351257833293940.882437108335303
1010.09655430021040320.1931086004208060.903445699789597
1020.07855383126478140.1571076625295630.921446168735219
1030.06247881987643250.1249576397528650.937521180123568
1040.0497054945945230.0994109891890460.950294505405477
1050.05086416117556940.1017283223511390.94913583882443
1060.04064118506267960.08128237012535920.95935881493732
1070.03492124508483570.06984249016967130.965078754915164
1080.03019077902191460.06038155804382930.969809220978085
1090.02303473235497350.04606946470994690.976965267645027
1100.02161852773705440.04323705547410870.978381472262946
1110.02614662104965920.05229324209931830.97385337895034
1120.1149111072557180.2298222145114360.885088892744282
1130.1110594276646530.2221188553293050.888940572335347
1140.525046650697770.949906698604460.47495334930223
1150.8454343937733540.3091312124532920.154565606226646
1160.8105306393388560.3789387213222880.189469360661144
1170.8689661104777510.2620677790444990.131033889522249
1180.8444716368526040.3110567262947920.155528363147396
1190.8150634622390490.3698730755219020.184936537760951
1200.8477646849759450.3044706300481110.152235315024055
1210.8254629351155770.3490741297688460.174537064884423
1220.7849334902857330.4301330194285340.215066509714267
1230.818847720195260.362304559609480.18115227980474
1240.7757365486661790.4485269026676430.224263451333821
1250.7369489540165550.526102091966890.263051045983445
1260.6872133158899050.625573368220190.312786684110095
1270.650566920403330.6988661591933390.349433079596669
1280.6088790431323540.7822419137352930.391120956867646
1290.5489801987195460.9020396025609090.451019801280454
1300.4861335365800890.9722670731601790.513866463419911
1310.485128648336970.970257296673940.51487135166303
1320.4814960701947770.9629921403895550.518503929805223
1330.4312329645811460.8624659291622920.568767035418854
1340.3820073780772920.7640147561545840.617992621922708
1350.5273207091994740.9453585816010520.472679290800526
1360.4890789326011860.9781578652023730.510921067398814
1370.4158281162725020.8316562325450040.584171883727498
1380.4267416556098680.8534833112197360.573258344390132
1390.3549492479801260.7098984959602530.645050752019874
1400.3195809303135840.6391618606271680.680419069686416
1410.2857656816791470.5715313633582940.714234318320853
1420.3372863850840110.6745727701680210.66271361491599
1430.478983318622290.957966637244580.52101668137771
1440.4021025236620420.8042050473240840.597897476337958
1450.3210487689393530.6420975378787050.678951231060647
1460.3096415230739780.6192830461479560.690358476926022
1470.2561318554651720.5122637109303440.743868144534828
1480.1601092463216490.3202184926432970.839890753678351
1490.3048112848837570.6096225697675140.695188715116243


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level00OK
5% type I error level20.0142857142857143OK
10% type I error level70.05OK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/1077ly1291136357.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/1077ly1291136357.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/1i6641291136357.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/1i6641291136357.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/2i6641291136357.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/2i6641291136357.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/3tf5p1291136357.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/3tf5p1291136357.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/4tf5p1291136357.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/4tf5p1291136357.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/5tf5p1291136357.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/5tf5p1291136357.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/6l74s1291136357.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/6l74s1291136357.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/7wyld1291136357.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/7wyld1291136357.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/8wyld1291136357.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/8wyld1291136357.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/9wyld1291136357.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/30/t1291136305y7zueqkzyi4955e/9wyld1291136357.ps (open in new window)


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