Home » date » 2010 » Nov » 20 »

ws7- mini tut

*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, 20 Nov 2010 12: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/Nov/20/t129025648941t8dw1dkrmn50f.htm/, Retrieved Sat, 20 Nov 2010 13:34:52 +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/20/t129025648941t8dw1dkrmn50f.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 «
9 24 14 11 12 24 26 9 25 11 7 8 25 23 9 17 6 17 8 30 25 9 18 12 10 8 19 23 9 18 8 12 9 22 19 9 16 10 12 7 22 29 10 20 10 11 4 25 25 10 16 11 11 11 23 21 10 18 16 12 7 17 22 10 17 11 13 7 21 25 10 23 13 14 12 19 24 10 30 12 16 10 19 18 10 23 8 11 10 15 22 10 18 12 10 8 16 15 10 15 11 11 8 23 22 10 12 4 15 4 27 28 10 21 9 9 9 22 20 10 15 8 11 8 14 12 10 20 8 17 7 22 24 10 31 14 17 11 23 20 10 27 15 11 9 23 21 10 34 16 18 11 21 20 10 21 9 14 13 19 21 10 31 14 10 8 18 23 10 19 11 11 8 20 28 10 16 8 15 9 23 24 10 20 9 15 6 25 24 10 21 9 13 9 19 24 10 22 9 16 9 24 23 10 17 9 13 6 22 23 10 24 10 9 6 25 29 10 25 16 18 16 26 24 10 26 11 18 5 29 18 10 25 8 12 7 32 25 10 17 9 17 9 25 21 10 32 16 9 6 29 26 10 33 11 9 6 28 22 10 13 16 12 5 17 22 10 32 12 18 12 28 22 10 25 12 12 7 29 23 10 29 14 18 10 26 30 10 22 9 14 9 25 23 10 18 10 15 8 14 17 10 17 9 16 5 25 23 10 20 10 10 8 26 23 10 15 12 11 8 20 25 10 20 14 14 10 18 24 10 33 14 9 6 32 24 10 29 10 12 8 25 23 10 23 14 17 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 time9 seconds
R Server'RServer@AstonUniversity' @ vre.aston.ac.uk


Multiple Linear Regression - Estimated Regression Equation
ConcernoverMistakes[t] = -20.5406175778344 + 1.85205065543305Month[t] + 0.800753683595023Doubtsaboutactions[t] + 0.233892111076654ParentalExpectations[t] + 0.20844977461566ParentalCriticism[t] + 0.571250810176502PersonalStandards[t] -0.108334921483045Organization[t] + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)-20.540617577834419.256187-1.06670.2877980.143899
Month1.852050655433051.8962850.97670.3302830.165141
Doubtsaboutactions0.8007536835950230.1307076.126300
ParentalExpectations0.2338921110766540.1339641.74590.0828440.041422
ParentalCriticism0.208449774615660.1695171.22970.220720.11036
PersonalStandards0.5712508101765020.0959755.952100
Organization-0.1083349214830450.103317-1.04860.2960390.148019


Multiple Linear Regression - Regression Statistics
Multiple R0.64099331025021
R-squared0.410872423785522
Adjusted R-squared0.387617387882318
F-TEST (value)17.6681053297763
F-TEST (DF numerator)6
F-TEST (DF denominator)152
p-value1.77635683940025e-15
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation4.47838506122403
Sum Squared Residuals3048.50177900237


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
12423.30591189430130.694088105698661
22520.03053887537274.9694611246273
31721.0052757760805-4.00527577608054
41818.1054640311387-0.105464031138674
51817.72577540998920.274224590010765
61617.8270340131175-1.82703401311751
72020.9669353500886-0.96693535008861
81622.5176755215724-6.51767552157243
91822.3856971696195-4.38569716961951
101720.5758193389779-3.57581933897792
112322.4193009914530.580699008547041
123022.31944150967827.6805584903218
132315.22862329327667.77137670672336
141819.1104416279066-1.11044162790658
151521.7839912762424-6.7839912762424
161217.915478548729-5.91547854872895
172119.56856849430431.4314315056957
181515.3238221486993-0.323822148699272
192019.7887124641590.21128753584099
203126.43162416030054.56837583969953
212725.30379070672121.69620929327879
223427.12452201821426.87547798178583
232119.74974079613771.25025920386234
243120.987771243585310.0122287564147
251919.4202293168146-0.420229316814631
261620.3090786014135-4.30907860141352
272021.6269845815146-1.62698458151457
282118.35704482214922.64295517785077
292222.0233101277447-0.0233101277447478
301719.5537828503148-2.5537828503148
312420.48271099123443.51728900876556
322530.5896852562428-5.5896852562428
332626.6567312769232-0.656731276923196
342524.22342508905770.77657491094229
351723.045122891964-6.04512289196399
363227.89724109795974.10275890204028
373323.75556155574039.24443844425972
381321.9687976203882-8.96879762038819
393227.91204288671924.08795711328084
402525.9293572358744-0.929357235874388
412927.08746971246051.91253028753948
422222.1267767157679-0.126776715767941
431817.31922335278070.68077664721929
441721.7607618394586-4.76076183945861
452022.3547629906172-2.35476299061719
461520.5459877648588-5.54598776485879
472022.2319043156402-2.23190431564016
483328.22615600426534.77384399573473
492922.2512964025946.748703597406
502326.6319917607078-3.63199176070779
512623.33393808632892.66606191367113
521819.0572045568099-1.05720455680992
532018.85336774429631.14663225570374
541111.8569662519076-0.856966251907634
552829.1391504790434-1.13915047904337
562623.43229711430432.56770288569571
572222.3892075268383-0.389207526838317
581720.2377578196325-3.23775781963248
591215.5903486600183-3.59034866001828
601420.9635424700856-6.96354247008556
611720.871071840472-3.87107184047204
622121.3887032327798-0.388703232779782
631922.99921279973-3.99921279972996
641823.2468530520286-5.24685305202856
651017.9645501066113-7.96455010661135
662924.39418483978984.60581516021023
673118.593809572314712.4061904276853
681923.0436062933947-4.04360629339472
69920.1246989779693-11.1246989779693
702022.6014881321463-2.60148813214627
712817.693420131388810.3065798686112
721918.25541337044730.744586629552658
733023.17816568274856.82183431725154
742927.1412651905231.85873480947699
752621.51864966003154.48135033996848
762319.61171219467763.38828780532242
771322.7696306151473-9.76963061514733
782122.7069504145405-1.70695041454046
791921.5925083983795-2.59250839837946
802822.97737756951745.0226224304826
812325.6717631113499-2.67176311134988
821813.91937831127614.0806216887239
832120.76752594128470.232474058715269
842021.8939221074588-1.89392210745884
852320.03254882182932.9674511781707
862120.81457978351440.185420216485577
872121.8549708563638-0.854970856363817
881522.9601236544929-7.96012365449285
892827.28990740362070.710092596379332
901917.68950998953241.31049001046759
912621.24375395623234.75624604376766
921013.3592202085389-3.35922020853889
931617.1550179477001-1.15501794770006
942221.14732552051230.852674479487732
951918.91520723051550.084792769484549
963128.86387540753292.1361245924671
973125.2303794172615.76962058273899
982924.82237582056174.17762417943828
991917.46000711611391.53999288388611
1002218.91977252836733.08022747163268
1012322.44404050766840.555959492331635
1021516.2213007844847-1.22130078448468
1032021.4067774452657-1.40677744526568
1041819.5916965986423-1.59169659864227
1052322.1310549953480.868945004652024
1062520.89174259250284.1082574074972
1072116.62480889629774.37519110370226
1082419.54050889011234.4594911098877
1092525.2842542064876-0.284254206487617
1101719.5415733289438-2.54157332894384
1111314.590920034779-1.59092003477895
1122818.31206598545469.68793401454535
1132120.32721598029360.6727840197064
1142528.2402549727791-3.24025497277912
115921.0230657884603-12.0230657884603
1161617.8649936604446-1.86499366044457
1171921.1927565169446-2.19275651694458
1181719.5105598387774-2.51055983877741
1192524.54234989280720.457650107192838
1202015.51102203613224.48897796386781
1212921.72837616400277.27162383599735
1221419.0319382805427-5.03193828054266
1232226.9807843689066-4.98078436890656
1241515.7566129258641-0.756612925864104
1251925.4706403155968-6.47064031559685
1262021.9365074008663-1.93650740086628
1271517.5261183627754-2.52611836277545
1282021.9219024004867-1.92190240048673
1291820.3175223942078-2.31752239420782
1303325.57499999310787.42500000689215
1312223.8817153183514-1.88171531835138
1321616.5259552703765-0.525955270376547
1331719.1237948992732-2.1237948992732
1341615.11555793247580.884442067524166
1352117.11003911100553.88996088899452
1362627.6211796228832-1.62117962288317
1371821.1341578075379-3.13415780753787
1381823.0934916296008-5.0934916296008
1391718.4649006478306-1.46490064783056
1402224.8487332677922-2.84873326779222
1413024.79359725135425.20640274864581
1423027.36471781443442.63528218556562
1432429.8857645038554-5.88576450385544
1442122.0669167791498-1.06691677914981
1452125.4142006337394-4.41420063373936
1462927.43919354272611.56080645727388
1473123.26179273493017.73820726506992
1482019.04820235704980.951797642950214
1491614.17357955579761.82642044420244
1502219.00322352035522.9967764796448
1512020.5031787470075-0.503178747007477
1522827.31180121681120.688198783188794
1533826.58362302307111.416376976929
1542219.26560666717542.73439333282455
1552025.7191898021532-5.71918980215319
1561718.0567002627514-1.05670026275139
1572824.54083329423793.45916670576211
1582224.1667158267939-2.16671582679389
1593126.11565976166314.88434023833688


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
100.09706704118348950.1941340823669790.90293295881651
110.3523937315236130.7047874630472260.647606268476387
120.741566177881040.516867644237920.25843382211896
130.7546971831618020.4906056336763960.245302816838198
140.7254484767998230.5491030464003530.274551523200177
150.7222331260299960.5555337479400070.277766873970004
160.6523287250372220.6953425499255550.347671274962778
170.5723867571705250.855226485658950.427613242829475
180.5418594976379090.9162810047241810.458140502362091
190.4746768820354030.9493537640708060.525323117964597
200.5058427191870520.9883145616258960.494157280812948
210.4595367988993250.919073597798650.540463201100675
220.4615022656115020.9230045312230050.538497734388498
230.3959674323419820.7919348646839640.604032567658018
240.6503967961502250.699206407699550.349603203849775
250.5814704078358780.8370591843282440.418529592164122
260.5529692208946710.8940615582106570.447030779105329
270.4892333828740320.9784667657480640.510766617125968
280.4394438196187580.8788876392375150.560556180381242
290.375597317633610.751194635267220.624402682366391
300.3202727906892250.6405455813784490.679727209310775
310.3629620800756560.7259241601513110.637037919924344
320.4384682808619950.876936561723990.561531719138005
330.3923908743408210.7847817486816420.607609125659179
340.3861762224596610.7723524449193230.613823777540339
350.4024822347189310.8049644694378620.597517765281069
360.3831703545198490.7663407090396970.616829645480152
370.5397889760306880.9204220479386230.460211023969312
380.737672203095430.5246555938091390.26232779690457
390.7285821679184440.5428356641631120.271417832081556
400.6868421397651520.6263157204696960.313157860234848
410.6576620025556670.6846759948886660.342337997444333
420.6057467149323730.7885065701352530.394253285067627
430.5565640123475030.8868719753049930.443435987652497
440.5418557683634410.9162884632731180.458144231636559
450.5155875849873650.968824830025270.484412415012635
460.5469266133009430.9061467733981140.453073386699057
470.5065035837407180.9869928325185630.493496416259282
480.4915276700125150.983055340025030.508472329987485
490.547042409487490.905915181025020.45295759051251
500.5224991616397490.9550016767205020.477500838360251
510.4855414435183180.9710828870366370.514458556481682
520.4368307603278960.8736615206557920.563169239672104
530.3948040599089570.7896081198179150.605195940091043
540.3502596862864780.7005193725729550.649740313713522
550.3118524346005220.6237048692010440.688147565399478
560.2822231878659350.564446375731870.717776812134065
570.241965379222740.4839307584454790.75803462077726
580.2202492497407240.4404984994814470.779750750259276
590.2061169261575810.4122338523151620.79388307384242
600.2587333467365410.5174666934730820.741266653263459
610.2525009302931990.5050018605863980.747499069706801
620.2165920987111340.4331841974222680.783407901288866
630.2054603211361670.4109206422723350.794539678863833
640.2463127265104330.4926254530208660.753687273489567
650.3219235874853270.6438471749706530.678076412514673
660.3202506915878110.6405013831756220.679749308412189
670.6420223536470220.7159552927059570.357977646352978
680.6372001251777710.7255997496444580.362799874822229
690.8266019964675010.3467960070649980.173398003532499
700.806821968698160.386356062603680.19317803130184
710.919416165358110.161167669283780.0805838346418899
720.9009752033729130.1980495932541740.0990247966270871
730.9254246520089460.1491506959821090.0745753479910544
740.9118300878247510.1763398243504980.0881699121752488
750.91353332191340.1729333561732010.0864666780866007
760.905613102717340.188773794565320.09438689728266
770.962709409449630.07458118110073870.0372905905503694
780.9539360111987650.09212797760246980.0460639888012349
790.9456252896303450.1087494207393090.0543747103696547
800.9485718978755230.1028562042489530.0514281021244765
810.939915985905970.1201680281880620.060084014094031
820.9385156749491290.1229686501017420.0614843250508711
830.9233385316367650.1533229367264690.0766614683632347
840.908823036675180.1823539266496420.0911769633248208
850.8985615779932490.2028768440135030.101438422006751
860.8810927302868740.2378145394262520.118907269713126
870.8573424373495980.2853151253008040.142657562650402
880.909265767454570.1814684650908580.090734232545429
890.891232397727670.2175352045446590.108767602272329
900.869291299282840.261417401434320.13070870071716
910.8715605388889320.2568789222221360.128439461111068
920.8608194275341910.2783611449316170.139180572465808
930.837228729993420.3255425400131610.162771270006581
940.8079727354703180.3840545290593650.192027264529682
950.7732820940468610.4534358119062780.226717905953139
960.7420484505183240.5159030989633530.257951549481676
970.762131802224180.4757363955516390.237868197775819
980.756060624930660.487878750138680.24393937506934
990.7192751377394320.5614497245211350.280724862260568
1000.6937075540770250.612584891845950.306292445922975
1010.6499134249314420.7001731501371160.350086575068558
1020.6104304153024740.7791391693950520.389569584697526
1030.5708582117825880.8582835764348240.429141788217412
1040.5284045659273720.9431908681452560.471595434072628
1050.4818238902379330.9636477804758670.518176109762067
1060.4624159195561080.9248318391122160.537584080443892
1070.4578279697095260.9156559394190520.542172030290474
1080.4678946111208110.9357892222416230.532105388879189
1090.4180484714399170.8360969428798330.581951528560083
1100.3946709846202370.7893419692404740.605329015379763
1110.3558516400834660.7117032801669320.644148359916534
1120.5752234395915220.8495531208169560.424776560408478
1130.5673438708425450.865312258314910.432656129157455
1140.5393894291358540.9212211417282930.460610570864147
1150.7571702979817530.4856594040364950.242829702018248
1160.7329947012418040.5340105975163920.267005298758196
1170.7205939496000640.5588121007998730.279406050399936
1180.6917327277600390.6165345444799220.308267272239961
1190.6408490525831830.7183018948336350.359150947416817
1200.6497517109130540.7004965781738920.350248289086946
1210.7020471644376520.5959056711246960.297952835562348
1220.706619746256260.5867605074874820.293380253743741
1230.7123835515225260.5752328969549480.287616448477474
1240.6591790318696720.6816419362606570.340820968130328
1250.7051892455662040.5896215088675930.294810754433796
1260.6753406703454740.6493186593090520.324659329654526
1270.6636775751517140.6726448496965720.336322424848286
1280.6271862085351140.7456275829297720.372813791464886
1290.5997998025579540.8004003948840930.400200197442046
1300.6706639022525950.658672195494810.329336097747405
1310.6129750712256810.7740498575486380.387024928774319
1320.5486312494142140.9027375011715720.451368750585786
1330.5465045273716840.9069909452566310.453495472628316
1340.4850634851079970.9701269702159930.514936514892003
1350.4425242411045130.8850484822090250.557475758895487
1360.4136292895515210.8272585791030430.586370710448479
1370.4172169583978590.8344339167957180.582783041602141
1380.4570914219548550.914182843909710.542908578045145
1390.3892987441054670.7785974882109340.610701255894533
1400.3171946465217060.6343892930434120.682805353478294
1410.4194161283338520.8388322566677040.580583871666148
1420.3650626141949540.7301252283899080.634937385805046
1430.2968768573865530.5937537147731060.703123142613447
1440.2228583556791680.4457167113583360.777141644320832
1450.2664017075775650.532803415155130.733598292422435
1460.1837295032859990.3674590065719990.816270496714
1470.2387194256747620.4774388513495240.761280574325238
1480.1475795712728910.2951591425457830.852420428727109
1490.07898494244129470.1579698848825890.921015057558705


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 level20.0142857142857143OK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/10vshg1290256541.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/10vshg1290256541.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/1prk41290256541.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/1prk41290256541.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/2prk41290256541.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/2prk41290256541.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/3hijp1290256541.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/3hijp1290256541.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/4hijp1290256541.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/4hijp1290256541.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/5hijp1290256541.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/5hijp1290256541.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/6s9ia1290256541.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/6s9ia1290256541.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/73jiv1290256541.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/73jiv1290256541.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/83jiv1290256541.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/83jiv1290256541.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/93jiv1290256541.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/20/t129025648941t8dw1dkrmn50f/93jiv1290256541.ps (open in new window)


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