Home » date » 2010 » Dec » 02 »

*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: Thu, 02 Dec 2010 15:07:12 +0000
 
Cite this page as follows:
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj.htm/, Retrieved Thu, 02 Dec 2010 16:05:53 +0100
 
BibTeX entries for LaTeX users:
@Manual{KEY,
    author = {{YOUR NAME}},
    publisher = {Office for Research Development and Education},
    title = {Statistical Computations at FreeStatistics.org, URL http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj.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 «
3 3 4 4 4 4 3 4 3 4 4 4 3 4 3 3 3 4 3 2 2 2 3 3 3 2 3 4 4 4 5 4 4 4 5 3 2 4 3 4 2 3 4 4 4 2 4 2 3 2 4 3 2 4 2 3 3 4 3 4 3 4 4 4 4 4 2 4 3 5 4 2 4 3 5 2 3 3 4 4 3 2 4 3 3 4 4 4 4 4 2 2 3 3 4 2 1 2 3 2 3 3 2 4 4 4 4 4 4 4 2 2 3 3 4 2 3 4 3 4 3 3 4 4 4 4 4 3 4 4 4 3 3 4 4 3 3 2 4 3 3 4 3 4 3 4 4 4 4 4 2 4 3 2 3 3 3 3 4 4 4 4 4 4 4 2 2 4 3 4 4 4 3 4 4 4 3 4 4 4 2 2 2 3 3 3 4 3 4 4 4 4 4 4 4 4 4 4 3 4 3 4 3 4 3 4 2 5 3 5 3 2 3 3 4 3 3 3 3 4 3 4 4 3 4 3 5 4 4 4 2 2 5 2 5 4 3 3 3 4 4 3 4 4 4 4 2 4 3 4 2 2 2 3 3 3 3 4 4 4 3 2 4 3 4 3 4 4 4 5 3 3 3 4 4 2 3 3 4 3 4 4 3 5 3 4 1 2 4 4 4 4 4 4 4 3 2 4 3 4 4 4 4 3 4 3 4 3 3 3 4 4 4 4 3 3 2 3 3 3 3 4 4 4 4 3 2 4 3 4 3 4 4 3 4 4 4 4 3 4 1 1 4 1 5 4 4 4 4 3 4 4 4 4 4 3 3 4 4 3 5 3 2 4 2 3 3 3 4 4 3 3 4 4 4 3 3 4 3 5 4 3 3 3 2 4 4 4 3 4 3 1 4 3 4 3 3 4 4 4 4 3 3 4 4 2 3 3 4 3 4 4 3 2 4 3 3 4 3 5 2 2 4 3 2 4 3 2 4 2 4 4 4 4 4 3 3 3 4 4 4 4 4 4 3 4 3 3 4 4 4 4 4 4 4 3 4 3 4 4 3 3 3 3 4 4 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 time7 seconds
R Server'Sir Ronald Aylmer Fisher' @ 193.190.124.24


Multiple Linear Regression - Estimated Regression Equation
SocialVisible[t] = + 1.12351677669589 + 0.205006149466121ManyFriends[t] + 0.0858332162777073MakeNewFriends[t] + 0.258524308214946QuiteAccepted[t] + 0.107736898186249IntendMakeNewFriends[t] + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)1.123516776695890.4603762.44040.0158670.007934
ManyFriends0.2050061494661210.0743542.75720.0065750.003288
MakeNewFriends0.08583321627770730.095350.90020.3695020.184751
QuiteAccepted0.2585243082149460.0953952.710.0075330.003767
IntendMakeNewFriends0.1077368981862490.0935281.15190.2512380.125619


Multiple Linear Regression - Regression Statistics
Multiple R0.438634013380361
R-squared0.192399797694162
Adjusted R-squared0.170273764754276
F-TEST (value)8.69563008501758
F-TEST (DF numerator)4
F-TEST (DF denominator)146
p-value2.52776170817093e-06
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation0.713165967765175
Sum Squared Residuals74.256431846452


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
133.54691291580986-0.546912915809856
243.288388607594910.711611392405088
343.558348950812020.441651049187978
433.07291481122241-0.0729148112224138
522.88981234366483-0.889812343664835
623.54691291580986-1.54691291580986
753.859655963462231.14034403653777
833.08338245812879-0.0833824581287911
923.54691291580986-1.54691291580986
1023.10625452813312-1.10625452813312
1143.159772686881940.840227313118055
1233.28838860759491-0.288388607594912
1333.75191906527598-0.751919065275978
1443.191119356315040.80888064368496
1543.191119356315040.80888064368496
1623.46107969953215-1.46107969953215
1732.975645559942540.0243544400574579
1843.751919065275980.248080934724022
1922.99754924185108-0.997549241851084
2022.49123607973476-0.491236079734758
2133.37524648325444-0.375246483254443
2243.751919065275980.248080934724022
2322.99754924185108-0.997549241851084
2423.28838860759491-1.28838860759491
2533.54691291580986-0.546912915809858
2643.666085848998270.333914151001729
2743.461079699532150.53892030046785
2833.26750958506819-0.267509585068194
2933.55834895081202-0.558348950812022
3043.751919065275980.248080934724022
3123.04130033438213-1.04130033438213
3233.46107969953215-0.46107969953215
3343.751919065275980.248080934724022
3423.08338245812879-1.08338245812879
3543.666085848998270.333914151001729
3643.546912915809860.453087084190142
3722.80397912738713-0.803979127387127
3833.66608584899827-0.666085848998271
3943.751919065275980.248080934724022
4043.493394757061030.506605242938968
4133.55834895081202-0.558348950812022
4243.276952572592750.723047427407252
4332.997549241851080.00245075814891616
4433.20255539131720-0.202555391317204
4533.49339475706103-0.493394757061032
4633.9569252147421-0.956925214742099
4723.0184282643778-1.01842826437780
4843.202555391317200.797444608682795
4943.546912915809860.453087084190142
5043.083382458128790.916617541871209
5122.80397912738713-0.803979127387127
5233.54691291580986-0.546912915809858
5333.08338245812879-0.0833824581287911
5433.85965596346223-0.859655963462227
5533.46107969953215-0.46107969953215
5623.3533428013459-1.3533428013459
5743.816873259026970.183126740973032
5842.96523418432221.03476581567780
5943.751919065275980.248080934724022
6033.08338245812879-0.0833824581287911
6143.493394757061030.506605242938968
6233.29982464259708-0.299824642597076
6343.644182167089730.355817832910271
6432.889812343664830.110187656335165
6533.75191906527598-0.751919065275978
6633.08338245812879-0.0833824581287911
6733.49339475706103-0.493394757061032
6843.493394757061030.506605242938968
6912.46906459041903-1.46906459041903
7043.644182167089730.355817832910271
7143.751919065275980.248080934724022
7233.43917601762361-0.439176017623608
7353.159772686881941.84022731311806
7433.46107969953215-0.46107969953215
7533.54691291580986-0.546912915809858
7633.39612550578116-0.396125505781161
7742.987081594944711.01291840505529
7843.493394757061030.506605242938968
7932.878376308662670.121623691337329
8033.54691291580986-0.546912915809858
8143.461079699532150.53892030046785
8223.3533428013459-1.3533428013459
8343.149037232568380.85096276743162
8433.39612550578116-0.396125505781161
8522.86790866175629-0.867908661756293
8643.159772686881940.840227313118055
8743.751919065275980.248080934724022
8833.46107969953215-0.46107969953215
8943.644182167089730.355817832910271
9043.461079699532150.53892030046785
9143.751919065275980.248080934724022
9233.66608584899827-0.666085848998271
9333.20255539131720-0.202555391317204
9443.083382458128790.916617541871209
9552.318544987797522.68145501220248
9632.824858149913850.175141850086155
9743.170240333788320.829759666211678
9843.288388607594910.711611392405088
9943.751919065275980.248080934724022
10043.751919065275980.248080934724022
10153.913174122211051.08682587778895
10243.288388607594910.711611392405088
10332.275494475955070.724505524044928
10443.546912915809860.453087084190142
10543.094818493130960.905181506869045
10643.751919065275980.248080934724022
10743.256073550066030.74392644993397
10843.461079699532150.53892030046785
10933.26750958506819-0.267509585068194
11043.288388607594910.711611392405088
11143.751919065275980.248080934724022
11243.751919065275980.248080934724022
11343.343632006414160.65636799358584
11443.493394757061030.506605242938968
11543.341906766343740.658093233656263
11643.546912915809860.453087084190142
11733.40756154078333-0.407561540783325
11843.288388607594910.711611392405088
11933.49339475706103-0.493394757061032
12033.25607355006603-0.256073550066030
12143.751919065275980.248080934724022
12243.493394757061030.506605242938968
12343.288388607594910.711611392405088
12443.751919065275980.248080934724022
12533.54691291580986-0.546912915809858
12633.3533428013459-0.353342801345901
12711.95228378139632-0.952283781396325
12843.751919065275980.248080934724022
12933.75191906527598-0.751919065275978
13043.341906766343740.658093233656263
13143.546912915809860.453087084190142
13233.75191906527598-0.751919065275978
13343.546912915809860.453087084190142
13443.751919065275980.248080934724022
13523.34190676634374-1.34190676634374
13643.95692521474210.0430747852579012
13733.3533428013459-0.353342801345901
13833.66608584899827-0.666085848998271
13943.546912915809860.453087084190142
14043.751919065275980.248080934724022
14133.54691291580986-0.546912915809858
14233.54691291580986-0.546912915809858
14333.34190676634374-0.341906766343737
14443.751919065275980.248080934724022
14543.751919065275980.248080934724022
14633.54691291580986-0.546912915809858
14744.01044337349092-0.0104433734909239
14832.975645559942540.0243544400574579
14943.644182167089730.355817832910271
15043.493394757061030.506605242938968
15143.180651709408660.819348290591337


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
80.3480495998066040.6960991996132080.651950400193396
90.3060333641147780.6120667282295550.693966635885222
100.8321745464665640.3356509070668730.167825453533437
110.9899610746506370.02007785069872610.0100389253493630
120.9813364934055650.03732701318887020.0186635065944351
130.9765605663559560.04687886728808720.0234394336440436
140.9744364109129840.05112717817403090.0255635890870155
150.9659724657035230.06805506859295310.0340275342964766
160.9850167940635720.02996641187285640.0149832059364282
170.9777360334746140.04452793305077220.0222639665253861
180.970280280439630.05943943912074110.0297197195603705
190.9745102656267710.05097946874645790.0254897343732290
200.9650809199601520.06983816007969660.0349190800398483
210.9498845411130950.1002309177738100.0501154588869049
220.9343554040817130.1312891918365740.065644595918287
230.9387000716385510.1225998567228970.0612999283614487
240.9659009249354260.06819815012914750.0340990750645737
250.9544860867405360.09102782651892730.0455139132594637
260.944071106622510.1118577867549790.0559288933774895
270.9443984731646350.1112030536707310.0556015268353654
280.9263479578771920.1473040842456150.0736520421228077
290.9102583671437830.1794832657124350.0897416328562174
300.8885852031948730.2228295936102530.111414796805127
310.8989985709726160.2020028580547670.101001429027384
320.8772704617971570.2454590764056860.122729538202843
330.8510852896101130.2978294207797740.148914710389887
340.8634187606146530.2731624787706950.136581239385347
350.839469715309850.3210605693802990.160530284690150
360.824038878586140.3519222428277210.175961121413860
370.811375292372710.3772494152545810.188624707627290
380.80249409139650.3950118172070010.197505908603500
390.7676607076609620.4646785846780750.232339292339038
400.7566689918032840.4866620163934310.243331008196716
410.7335033312328360.5329933375343280.266496668767164
420.7442942141202650.511411571759470.255705785879735
430.7091055882675320.5817888234649370.290894411732468
440.6660780456321440.6678439087357130.333921954367856
450.6365980356807230.7268039286385540.363401964319277
460.6783443038317350.643311392336530.321655696168265
470.7028727223304150.594254555339170.297127277669585
480.7428847248015140.5142305503969720.257115275198486
490.7225722093630790.5548555812738420.277427790636921
500.7715800164114370.4568399671771260.228419983588563
510.7769778401339830.4460443197320340.223022159866017
520.7594721102836290.4810557794327420.240527889716371
530.7200718610107760.5598562779784480.279928138989224
540.7436103040107470.5127793919785050.256389695989253
550.7199435440973870.5601129118052250.280056455902613
560.8135395981524490.3729208036951030.186460401847551
570.7871569521572020.4256860956855960.212843047842798
580.8212412713504170.3575174572991650.178758728649583
590.7949189779711890.4101620440576220.205081022028811
600.7594649534562330.4810700930875350.240535046543767
610.7562190533397070.4875618933205860.243780946660293
620.7348865193626950.530226961274610.265113480637305
630.7134585418777370.5730829162445260.286541458122263
640.6835481340650660.6329037318698680.316451865934934
650.6887493892508270.6225012214983450.311250610749173
660.6458179872820680.7083640254358640.354182012717932
670.6213173305789910.7573653388420180.378682669421009
680.6108569540136040.7782860919727930.389143045986396
690.7484099304985570.5031801390028860.251590069501443
700.7223540441814110.5552919116371780.277645955818589
710.68631869151990.6273626169602010.313681308480100
720.6613459134960270.6773081730079460.338654086503973
730.8767308845128190.2465382309743620.123269115487181
740.8659036073545420.2681927852909160.134096392645458
750.8588129069069850.2823741861860290.141187093093015
760.8504910940315230.2990178119369530.149508905968477
770.8861458859339510.2277082281320970.113854114066049
780.8766246990003770.2467506019992460.123375300999623
790.8551353821710360.2897292356579280.144864617828964
800.8494206867776570.3011586264446860.150579313222343
810.8358196864344660.3283606271310690.164180313565534
820.9094511739041850.1810976521916300.0905488260958152
830.9170462715943910.1659074568112170.0829537284056086
840.9159141815254090.1681716369491820.0840858184745912
850.9310703689166030.1378592621667930.0689296310833967
860.9433079760998970.1133840478002050.0566920239001026
870.9298072810087180.1403854379825650.0701927189912824
880.9243835225827840.1512329548344320.0756164774172162
890.913830981483790.1723380370324210.0861690185162105
900.9032053029158320.1935893941683370.0967946970841683
910.8829097930640060.2341804138719890.117090206935994
920.8843439065581360.2313121868837280.115656093441864
930.8725369994693050.2549260010613910.127463000530695
940.8768393890521960.2463212218956090.123160610947804
950.9989172761901540.002165447619691740.00108272380984587
960.9985468461256940.002906307748611710.00145315387430586
970.9987836544702790.002432691059442280.00121634552972114
980.9985296258333070.002940748333386220.00147037416669311
990.9978256542796750.004348691440649690.00217434572032485
1000.9968197734456620.006360453108676620.00318022655433831
1010.9978507122824750.004298575435049260.00214928771752463
1020.9974207918583130.005158416283374540.00257920814168727
1030.9965291289926850.006941742014630920.00347087100731546
1040.995477011105740.009045977788520420.00452298889426021
1050.9974214744266860.005157051146628890.00257852557331445
1060.9961833953169450.007633209366109230.00381660468305462
1070.9969320834293040.006135833141392580.00306791657069629
1080.99681979427860.00636041144280190.00318020572140095
1090.995652819009810.00869436198037930.00434718099018965
1100.9947914596039750.01041708079204910.00520854039602457
1110.9923588573216780.01528228535664420.00764114267832211
1120.9889550914692450.02208981706150980.0110449085307549
1130.9934984771612850.01300304567743070.00650152283871537
1140.9910586179544430.01788276409111420.00894138204555712
1150.9919578290134450.01608434197311090.00804217098655546
1160.9902340370745250.01953192585095010.00976596292547505
1170.9857717587560840.0284564824878310.0142282412439155
1180.9856364952377150.02872700952457000.0143635047622850
1190.9876842595153620.02463148096927610.0123157404846381
1200.9858194580544570.02836108389108650.0141805419455432
1210.9788716339078430.04225673218431380.0211283660921569
1220.970446798891460.05910640221707940.0295532011085397
1230.9736753859940680.05264922801186390.0263246140059319
1240.961925548291230.07614890341753830.0380744517087691
1250.9543229027566430.09135419448671410.0456770972433571
1260.9387401664101230.1225196671797540.0612598335898768
1270.9539656285008880.0920687429982250.0460343714991125
1280.935075320811890.1298493583762210.0649246791881103
1290.9492967043371720.1014065913256560.0507032956628281
1300.9791762930895650.04164741382087030.0208237069104352
1310.9830825115134740.03383497697305140.0169174884865257
1320.992379588501670.01524082299666120.00762041149833062
1330.9956637140493670.008672571901264950.00433628595063248
1340.9916482638790350.01670347224192980.00835173612096492
1350.9972084465461670.005583106907665850.00279155345383293
1360.996316938625290.007366122749420950.00368306137471047
1370.9925684941041680.01486301179166400.00743150589583201
1380.9832995060329790.03340098793404190.0167004939670209
1390.9936348228473650.01273035430526920.0063651771526346
1400.983618302634820.03276339473035980.0163816973651799
1410.971088264762770.05782347047446020.0289117352372301
1420.9567075946859020.08658481062819630.0432924053140982
1430.9167594775569360.1664810448861290.0832405224430644


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level180.132352941176471NOK
5% type I error level430.316176470588235NOK
10% type I error level570.419117647058824NOK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/10a92e1291302421.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/10a92e1291302421.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/138521291302421.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/138521291302421.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/2e0n51291302421.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/2e0n51291302421.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/3e0n51291302421.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/3e0n51291302421.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/4e0n51291302421.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/4e0n51291302421.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/56rmq1291302421.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/56rmq1291302421.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/66rmq1291302421.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/66rmq1291302421.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/7zi3t1291302421.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/7zi3t1291302421.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/8zi3t1291302421.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/8zi3t1291302421.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/9zi3t1291302421.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t129130235366hc4rpoc9o0nfj/9zi3t1291302421.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