Home » date » 2010 » Nov » 23 »

*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, 23 Nov 2010 21:29:39 +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/23/t12905476694etcg976uxaubrf.htm/, Retrieved Tue, 23 Nov 2010 22:28:00 +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/23/t12905476694etcg976uxaubrf.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 «
41 12 14 12 39 11 18 11 30 15 11 14 31 6 12 12 34 13 16 21 35 10 18 12 39 12 14 22 34 14 14 11 36 12 15 10 37 6 15 13 38 10 17 10 36 12 19 8 38 12 10 15 39 11 16 14 33 15 18 10 32 12 14 14 36 10 14 14 38 12 17 11 39 11 14 10 32 12 16 13 32 11 18 7 31 12 11 14 39 13 14 12 37 11 12 14 39 9 17 11 41 13 9 9 36 10 16 11 33 14 14 15 33 12 15 14 34 10 11 13 31 12 16 9 27 8 13 15 37 10 17 10 34 12 15 11 34 12 14 13 32 7 16 8 29 6 9 20 36 12 15 12 29 10 17 10 35 10 13 10 37 10 15 9 34 12 16 14 38 15 16 8 35 10 12 14 38 10 12 11 37 12 11 13 38 13 15 9 33 11 15 11 36 11 17 15 38 12 13 11 32 14 16 10 32 10 14 14 32 12 11 18 34 13 12 14 32 5 12 11 37 6 15 12 39 12 16 13 29 12 15 9 37 11 12 10 35 10 12 15 30 7 8 20 38 12 13 12 34 14 11 12 31 11 14 14 34 12 15 13 35 13 10 11 36 14 11 17 30 11 12 12 39 12 15 13 35 12 15 14 38 8 14 13 31 11 16 15 34 14 15 13 38 14 15 10 34 12 13 11 39 9 12 19 37 13 17 13 34 11 13 17 28 12 15 13 37 12 13 9 33 12 15 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'George Udny Yule' @ 72.249.76.132


Multiple Linear Regression - Estimated Regression Equation
Connected[t] = + 32.3319878002112 + 0.0736930507943348Software[t] + 0.158414769830048Happiness[t] -0.0578124530341167Depression[t] + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)32.33198780021123.21373510.060600
Software0.07369305079433480.1249310.58990.5561210.27806
Happiness0.1584147698300480.135191.17180.2430450.121523
Depression-0.05781245303411670.100457-0.57550.5657760.282888


Multiple Linear Regression - Regression Statistics
Multiple R0.158387868304106
R-squared0.0250867168259188
Adjusted R-squared0.00657570512008165
F-TEST (value)1.35523207615975
F-TEST (DF numerator)3
F-TEST (DF denominator)158
p-value0.25857296513043
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation3.36401381269591
Sum Squared Residuals1788.02105125741


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
14134.7403617509556.25963824904502
23935.35814023251453.64185976748549
33034.3705716877792-4.37057168777918
43133.9813739065284-2.98137390652844
53434.6105722641019-0.610572264101924
63535.2266347286861-0.226634728686064
73934.16223722061344.83776277938662
83434.9455603055773-0.945560305577329
93635.01440142685280.985598573147177
103734.39880576298452.60119423701554
113835.18384486492422.81615513507575
123635.76368541224120.236314587758753
133833.9332653125324.066734687468
143934.86787333375214.13212666624793
153335.710724888726-2.71072488872597
163234.6247368448863-2.62473684488631
173634.47735074329761.52264925670236
183835.27341851347882.72658148652120
193934.78229360622844.21770639377156
203234.9993788375805-2.99937883758052
213235.589390044651-3.58939004465098
223134.1494925353962-3.14949253539617
233934.81405480174894.18594519825112
243734.23421425443192.76578574556812
253935.05233936109583.9476606389042
264134.1954183117016.80458168829901
273634.96761764206011.03238235793992
283334.7143104934409-1.71431049344086
293334.7831516147164-1.78315161471636
303434.0599188868416-0.0599188868416135
313135.230628649717-4.23062864971699
322734.1137374188448-7.1137374188448
333735.18384486492421.81615513507575
343434.9565889738187-0.956588973818707
353434.6825492979204-0.682549297920426
363234.9199758487794-2.91997584877943
372933.0436299727654-4.04362997276536
383634.89877652078461.10122347921541
392935.1838448649242-6.18384486492425
403534.55018578560410.449814214395941
413734.92482777829832.07517222170173
423434.9415663845464-0.941566384546404
433835.50952025513412.49047974486589
443534.16052120363750.839478796362455
453834.33395856273993.66604143726011
463734.20730498843032.79269501156972
473835.14590693068132.85409306931872
483334.8828959230244-1.88289592302437
493634.9684756505481.031524349452
503834.63975943415863.36024056584139
513235.3202022982715-3.32020229827154
523234.4773507432976-2.47735074329764
533233.9182427232597-1.9182427232597
543434.3816003560205-0.381600356020549
553233.9654933087682-1.96549330876822
563734.45661821601862.54338178398142
573934.99937883758054.00062116241948
582935.0722138798869-6.07221387988694
593734.46546406656832.53453593343165
603534.10270875060340.897291249396572
613032.9589082537296-2.95890825372965
623834.58194698112453.41805301887551
633434.4125035430531-0.412503543053069
643134.551043794092-3.55104379409197
653434.8409640677505-0.840964067750473
663534.23820817546280.761791824537197
673634.12344127788251.87655872211751
683034.3498391605001-4.34983916050011
693934.84096406775054.15903593224953
703534.78315161471640.216848385283643
713834.38777709474313.61222290525691
723134.8100608807180-3.81006088071795
733434.9883501693391-0.988350169339143
743835.16178752844152.83821247155851
753434.6397594341586-0.639759434158611
763933.79776588767265.20223411232737
773735.23148665820491.76851334179510
783434.2191916651596-0.219191665159577
792834.8409640677505-6.84096406775047
803734.75538434022682.24461565977316
813334.9565889738187-1.95658897381871
823735.17281619668291.82718380331713
833535.0722138798869-0.07221387988694
843735.05719129061461.94280870938536
853234.8250834699903-2.82508346999025
863334.5351631963318-1.53516319633176
873834.61988491536753.38011508463253
883334.7403617509545-1.74036175095454
892934.4085096220221-5.40850962202215
903333.0533338318030-0.0533338318030432
913134.9367144550276-3.93671445502756
923634.62958877440511.37041122559485
933534.84096406775050.159035932249526
943234.5669243918522-2.56692439185219
952934.6975718871927-5.69757188719273
963934.96761764206014.03238235793992
973734.26597544995232.73402455004768
983534.57709505160570.422904948394345
993735.27341851347881.72658148652120
1003234.8670153252642-2.86701532526415
1013835.47861706810162.52138293189841
1023734.11858934836362.88141065163635
1033635.27827044299760.721729557002357
1043234.2492368437042-2.24923684370418
1053334.5938336578538-1.59383365785379
1064033.54360073056556.45639926943451
1073835.11500374364882.88499625635125
1084134.66752670864816.33247329135188
1093633.85957226173772.14042773826233
1104333.04448798125339.95551201874672
1113034.7831516147164-4.78315161471636
1123134.2390661839507-3.23906618395072
1133234.5660663833643-2.56606638336428
1143234.4932313410579-2.49323134105786
1153735.22663472868611.77336527131394
1163735.24650924747721.75349075252279
1173334.6984298956806-1.69842989568064
1183434.3877770947431-0.387777094743087
1193334.8401060592626-1.84010605926256
1203834.56692439185223.43307560814781
1213334.1764018013978-1.17640180139776
1223134.6984298956806-3.69842989568064
1233834.95658897381873.04341102618129
1243735.27741243450971.72258756549027
1253335.0302820246130-2.03028202461304
1263134.8608385865416-3.86083858654162
1273935.29946977099253.70053022900752
1284435.25753791571868.74246208428142
1293335.3691689007559-2.36916890075589
1303534.76727101695610.232728983043861
1313234.4923733325699-2.49237333256994
1322833.412095226737-5.41209522673704
1334034.71962922367555.28037077632452
1342734.6516461108879-7.65164611088791
1353734.89877652078462.10122347921541
1363234.9415663845464-2.94156638454640
1372833.4081013057061-5.40810130570611
1383434.551043794092-0.551043794091975
1393033.8864815277393-3.88648152773926
1403534.66181677064140.338183229358632
1413134.3608678287415-3.36086782874149
1423234.7196292236755-2.71962922367548
1433034.7204872321634-4.7204872321634
1443034.9614409033375-4.96144090333755
1453134.8250834699903-3.82508346999025
1464034.82023154047145.17976845952859
1473235.1308843414090-3.13088434140897
1483634.20730498843031.79269501156972
1493234.4813446643286-2.48134466432856
1503533.32252157818251.67747842181752
1513834.68872603664303.31127396335704
1524234.36657776674827.63342223325175
1533435.009549497334-1.00954949733398
1543533.98137390652841.01862609347156
1553533.24882852738811.75117147261185
1563333.9403000597425-0.940300059742456
1573634.62958877440511.37041122559485
1583234.1825785401203-2.1825785401203
1593335.3691689007559-2.36916890075589
1603434.6816912894325-0.68169128943251
1613233.7818852899124-1.78188528991241
1623434.0559249658107-0.0559249658106891


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
70.9296590753041760.1406818493916470.0703409246958236
80.8706590962029350.258681807594130.129340903797065
90.7892478009905250.4215043980189510.210752199009475
100.7092574445009820.5814851109980360.290742555499018
110.6117162750158860.7765674499682270.388283724984114
120.5464141320867340.9071717358265330.453585867913266
130.6155024177310210.7689951645379580.384497582268979
140.572283549892070.855432900215860.42771645010793
150.5626431202044380.8747137595911230.437356879795562
160.5636751511478180.8726496977043650.436324848852182
170.4804530281700690.9609060563401380.519546971829931
180.4270444180698580.8540888361397150.572955581930142
190.445541698715250.89108339743050.55445830128475
200.4777760928273520.9555521856547050.522223907172648
210.5031822295591390.9936355408817210.496817770440861
220.5040260722195560.9919478555608880.495973927780444
230.542388502915750.91522299416850.45761149708425
240.4983318596400950.996663719280190.501668140359905
250.4741111225421730.9482222450843460.525888877457827
260.637117361040830.725765277918340.36288263895917
270.576501885845460.846996228309080.42349811415454
280.541675568639670.916648862720660.45832443136033
290.5133477895176120.9733044209647760.486652210482388
300.4695639609075150.939127921815030.530436039092485
310.5215794324489910.9568411351020180.478420567551009
320.7755783287634620.4488433424730750.224421671236538
330.7380966717007760.5238066565984470.261903328299224
340.6969286261178360.6061427477643270.303071373882164
350.6506155777258340.6987688445483330.349384422274166
360.6454135989208340.7091728021583320.354586401079166
370.6641392199252080.6717215601495840.335860780074792
380.6154263092003720.7691473815992550.384573690799627
390.7250947170095490.5498105659809030.274905282990451
400.6789228289138150.6421543421723710.321077171086185
410.6464422919194720.7071154161610560.353557708080528
420.600730356358710.798539287282580.39926964364129
430.5649067326293740.8701865347412520.435093267370626
440.5154815709878240.9690368580243520.484518429012176
450.515223764955730.969552470088540.48477623504427
460.4870671729794630.9741343459589250.512932827020537
470.460218901921890.920437803843780.53978109807811
480.4301024921033410.8602049842066820.569897507896659
490.3871174133640210.7742348267280430.612882586635979
500.3744995927139260.7489991854278520.625500407286074
510.391166892716290.782333785432580.60883310728371
520.3701828596116750.740365719223350.629817140388325
530.3429615289249220.6859230578498440.657038471075078
540.3019769396770980.6039538793541960.698023060322902
550.2710779937482610.5421559874965210.72892200625174
560.2618197972585990.5236395945171990.738180202741401
570.2760496235172860.5520992470345720.723950376482714
580.3887706829900790.7775413659801580.611229317009921
590.3647204682202070.7294409364404140.635279531779793
600.3232172187686450.646434437537290.676782781231355
610.3104080847575640.6208161695151290.689591915242436
620.3068500834036710.6137001668073410.693149916596329
630.2712854998361290.5425709996722590.72871450016387
640.276472241149980.552944482299960.72352775885002
650.2412264030618080.4824528061236160.758773596938192
660.2090279014116050.418055802823210.790972098588395
670.1857092490042610.3714184980085230.814290750995739
680.2100128825427590.4200257650855170.789987117457241
690.2267434136062290.4534868272124590.77325658639377
700.1933765796178760.3867531592357520.806623420382124
710.2006373991546440.4012747983092880.799362600845356
720.2098693536708910.4197387073417830.790130646329109
730.1818334992786230.3636669985572470.818166500721377
740.1722263756469870.3444527512939740.827773624353013
750.1463713041174120.2927426082348240.853628695882588
760.1884977823310740.3769955646621490.811502217668925
770.1663093197119340.3326186394238680.833690680288066
780.1393894943610580.2787789887221160.860610505638942
790.2348782643988690.4697565287977380.765121735601131
800.2176289634009680.4352579268019350.782371036599032
810.1960347432372400.3920694864744810.80396525676276
820.1748422121219060.3496844242438120.825157787878094
830.1476457341398670.2952914682797350.852354265860133
840.1307800993487050.261560198697410.869219900651295
850.1231755566725340.2463511133450690.876824443327466
860.1053262985477180.2106525970954360.894673701452282
870.1056090789962840.2112181579925680.894390921003716
880.0908903995157520.1817807990315040.909109600484248
890.1223071459433850.2446142918867700.877692854056615
900.1005541268104890.2011082536209790.89944587318951
910.1083334998799530.2166669997599060.891666500120047
920.0919990927796740.1839981855593480.908000907220326
930.07446526277445850.1489305255489170.925534737225541
940.06755506619995260.1351101323999050.932444933800047
950.09589483391055710.1917896678211140.904105166089443
960.1038697432715350.2077394865430700.896130256728465
970.09726993945934450.1945398789186890.902730060540656
980.07912688602806120.1582537720561220.920873113971939
990.06725960264008780.1345192052801760.932740397359912
1000.0621152911203740.1242305822407480.937884708879626
1010.05687968369699270.1137593673939850.943120316303007
1020.05350740553767830.1070148110753570.946492594462322
1030.04319802492498720.08639604984997440.956801975075013
1040.03681198738532870.07362397477065740.963188012614671
1050.02973714723962930.05947429447925850.97026285276037
1060.06000664830598830.1200132966119770.939993351694012
1070.05731937056719550.1146387411343910.942680629432805
1080.1064554678116330.2129109356232660.893544532188367
1090.0969134288848670.1938268577697340.903086571115133
1100.4094883824114050.8189767648228090.590511617588595
1110.4381803690806310.8763607381612620.561819630919369
1120.4168645435139190.8337290870278370.583135456486081
1130.3944803849665230.7889607699330460.605519615033477
1140.3633325146449540.7266650292899070.636667485355046
1150.3315519491209090.6631038982418170.668448050879091
1160.3011195906979970.6022391813959940.698880409302003
1170.2632762917857720.5265525835715440.736723708214228
1180.2234477292860950.446895458572190.776552270713905
1190.2005770485513440.4011540971026890.799422951448656
1200.2260116087697610.4520232175395220.773988391230239
1210.1907333000421450.3814666000842900.809266699957855
1220.1804009054136670.3608018108273350.819599094586333
1230.1775940131703270.3551880263406540.822405986829673
1240.1534186528370380.3068373056740750.846581347162962
1250.1289287569257160.2578575138514320.871071243074284
1260.1272340344801630.2544680689603270.872765965519837
1270.1245280619042010.2490561238084030.875471938095799
1280.3905164665142420.7810329330284840.609483533485758
1290.3462451668355630.6924903336711260.653754833164437
1300.3023603826873160.6047207653746320.697639617312684
1310.2780057164731040.5560114329462080.721994283526896
1320.3180292185139960.6360584370279920.681970781486004
1330.406198916083820.812397832167640.59380108391618
1340.5693614662602260.8612770674795470.430638533739774
1350.560053903870440.8798921922591210.439946096129560
1360.5109547301223820.9780905397552360.489045269877618
1370.6282671780537310.7434656438925370.371732821946269
1380.5618639549420180.8762720901159650.438136045057982
1390.6000279694863170.7999440610273670.399972030513683
1400.5406492152301420.9187015695397170.459350784769858
1410.5225568012832070.9548863974335860.477443198716793
1420.4707770559657810.9415541119315610.529222944034219
1430.5207704454640450.958459109071910.479229554535955
1440.5894584162662260.8210831674675490.410541583733774
1450.621032739351690.757934521296620.37896726064831
1460.7930372187845820.4139255624308360.206962781215418
1470.818356068896330.363287862207340.18164393110367
1480.7527837785440380.4944324429119240.247216221455962
1490.7659919409789370.4680161180421270.234008059021063
1500.6760569365494090.6478861269011820.323943063450591
1510.8118522704316410.3762954591367180.188147729568359
1520.9959656149387960.00806877012240880.0040343850612044
1530.9870785691229820.02584286175403620.0129214308770181
1540.9859117227628960.02817655447420760.0140882772371038
1550.9801478807381940.03970423852361230.0198521192618062


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level10.00671140939597315OK
5% type I error level40.0268456375838926OK
10% type I error level70.0469798657718121OK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/10ienb1290547768.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/10ienb1290547768.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/1tdpz1290547768.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/1tdpz1290547768.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/2tdpz1290547768.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/2tdpz1290547768.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/3m4pk1290547768.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/3m4pk1290547768.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/4m4pk1290547768.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/4m4pk1290547768.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/5m4pk1290547768.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/5m4pk1290547768.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/6wv6n1290547768.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/6wv6n1290547768.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/77n5q1290547768.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/77n5q1290547768.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/87n5q1290547768.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/87n5q1290547768.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/97n5q1290547768.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Nov/23/t12905476694etcg976uxaubrf/97n5q1290547768.ps (open in new window)


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





Copyright

Creative Commons License

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

Software written by Ed van Stee & Patrick Wessa


Disclaimer

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


Privacy Policy

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

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

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

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

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

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

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

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

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


FreeStatistics.org is powered by