Home » date » 2010 » Dec » 13 »

Paper Celebrity MR

*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: Mon, 13 Dec 2010 19:43:25 +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/13/t1292270254hirx8j083vo4k4i.htm/, Retrieved Mon, 13 Dec 2010 20:57:37 +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/13/t1292270254hirx8j083vo4k4i.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 «
6 2 1 3 11 16 14 5 4 1 1 1 11 13 11 12 5 1 1 3 15 16 11 11 4 1 1 3 11 6 9 6 4 1 2 3 9 11 11 12 6 1 1 3 14 13 16 11 6 1 1 1 12 15 13 12 4 2 4 3 6 9 11 7 4 1 1 3 4 6 4 8 6 1 1 1 13 11 15 13 4 1 1 1 12 9 13 12 6 1 1 3 10 4 13 13 5 1 1 1 12 8 13 12 4 1 3 3 9 11 11 12 6 2 1 3 16 16 15 11 3 2 1 1 13 5 12 12 5 1 1 1 12 6 14 12 6 1 6 1 11 7 13 12 4 2 1 3 12 16 13 11 6 2 1 1 12 12 12 13 2 1 1 3 11 7 13 9 7 2 1 3 16 13 14 11 5 1 1 1 9 12 13 11 2 2 1 3 8 10 15 11 4 1 1 1 11 12 12 9 4 2 1 4 9 8 10 11 6 2 1 3 16 15 14 12 6 1 1 3 14 15 13 12 5 2 1 3 10 10 11 10 6 1 4 3 14 13 15 12 6 2 1 1 16 16 14 12 4 1 1 3 12 10 13 12 6 2 1 3 13 14 14 9 6 1 1 3 16 16 16 9 6 1 1 3 15 13 13 12 2 2 1 1 5 4 5 14 4 2 1 3 12 7 11 12 5 1 1 1 11 15 10 11 3 1 1 2 15 5 11 9 7 2 1 3 15 14 15 11 5 1 1 1 12 11 15 7 3 1 1 1 5 8 12 15 8 1 1 3 16 14 15 11 8 1 1 3 16 12 15 12 5 2 2 1 12 12 14 12 6 2 1 3 6 15 11 9 3 2 1 3 7 8 12 12 5 2 1 3 14 16 12 11 4 2 2 3 8 9 12 11 5 1 4 3 12 13 13 8 5 2 1 1 10 8 9 7 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'RServer@AstonUniversity' @ vre.aston.ac.uk


Multiple Linear Regression - Estimated Regression Equation
Celebrity[t] = + 0.500464733012453 -0.14217988308427Gender[t] + 0.0812069443486665Raised[t] + 0.092011267173835Marital[t] + 0.16911978017478Popularity[t] + 0.0953250302116789KnowingPeople[t] + 0.129653715719074Liked[t] -0.0261759550770048FindingFriends[t] + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)0.5004647330124530.8129150.61560.5391450.269572
Gender-0.142179883084270.18642-0.76270.4469510.223476
Raised0.08120694434866650.1022560.79410.4284720.214236
Marital0.0920112671738350.0892661.03080.3044570.152228
Popularity0.169119780174780.0412384.10117e-053.5e-05
KnowingPeople0.09532503021167890.0320052.97840.0034240.001712
Liked0.1296537157190740.0501542.58510.0107720.005386
FindingFriends-0.02617595507700480.049327-0.53070.5965060.298253


Multiple Linear Regression - Regression Statistics
Multiple R0.680555914549806
R-squared0.463156352828723
Adjusted R-squared0.435925153334528
F-TEST (value)17.0082978874086
F-TEST (DF numerator)7
F-TEST (DF denominator)138
p-value4.44089209850063e-16
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation1.04735303859423
Sum Squared Residuals151.378877468454


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
165.643136022705540.356863977294461
244.74312544811085-0.743125448110848
355.91577814886968-0.915778148869679
444.15762107000065-0.157621070000646
544.47946530603427-0.479465306034267
666.10895185665523-0.108951856655235
765.362202720147140.637797279852865
843.932569686084660.0674303139153416
942.273162120027811.72683787997219
1065.383153855836340.616846144163656
1144.79025253887706-0.790252538877062
1264.133234406739771.86676559326023
1354.694927508665380.305072491334617
1444.56067225038293-0.560672250382935
1566.46133290883649-0.461332908836487
1634.30623859940178-1.30623859940178
1754.63393116396110.3660688360389
1864.836517420022261.16348257997774
1945.52554635669922-1.52554635669922
2064.778218075631751.22178192436825
2124.69303309785761-2.69303309785761
2276.045704102482380.954295897517624
2354.595044244064760.404955755935236
2424.53642448616818-2.53642448616818
2544.85598199884926-0.855981998849259
2643.958636894498060.0413631055019396
2766.21017820782873-0.210178207828729
2865.884464814844360.115535185155635
2954.382225138718440.617774861281558
3066.19674301890516-0.196743018905156
3166.12148070369274-0.121480703692738
3245.06960010343641-1.06960010343641
3365.686021702323720.313978297676275
3466.78551841779384-0.785518417793841
3565.862934534595790.137065465404213
3621.898027407604330.101972592395666
3744.38213769827896-0.382137698278955
3854.830297747892140.169702252107863
3934.82754345952139-1.82754345952139
4076.101563068238350.89843693176165
4155.37108980612359-0.371089806123593
4233.30290746649184-0.302907466491836
4386.41286273149741.5871372685026
4486.196036715997041.80396328400296
4555.14490840649557-0.14490840649557
4664.208547124154721.79145287584528
4733.76151754333581-0.76151754333581
4855.7341322013297-0.734132201329704
4944.13334525314794-0.13334525314794
5055.70389984742547-0.703899847425466
5153.826772977740281.17322702225972
5265.348892708562680.651107291437319
5355.76236627331116-0.762366273311165
5466.02490002734767-0.024900027347671
5564.686227534754291.31377246524571
5643.474378203852030.525621796147967
5786.516340492139471.48365950786053
5864.853795936912221.14620406308778
5944.06029103922966-0.060291039229664
6065.68791611313150.3120838868685
6155.50361181277025-0.503611812770245
6255.63290585015621-0.63290585015621
6366.52885166062481-0.528851660624815
6466.20126153538483-0.201261535384833
6565.551634871336740.448365128663263
6664.419973439388311.58002656061169
6765.631248620014730.368751379985267
6865.793785459461110.206214540538887
6975.361072251352871.63892774864713
7044.09046575402852-0.0904657540285158
7144.09738051687767-0.0973805168776744
7235.26764163194896-2.26764163194896
7366.51719187459246-0.517191874592461
7455.98443551988447-0.98443551988447
7555.34067243989856-0.340672439898557
7633.63103585113242-0.631035851132423
7755.50979222007334-0.509792220073337
7844.67235420006202-0.672354200062023
7934.51179141399803-1.51179141399803
8076.733166507639830.266833492360169
8143.395716999773510.60428300022649
8245.5805539400022-1.5805539400022
8355.45870715422913-0.458707154229126
8465.15002237947520.8499776205248
8523.41427387010287-1.41427387010287
8622.48188002633295-0.481880026332946
8764.866151637754241.13384836224576
8843.482169978776460.517830021223539
8954.919267489921750.0807325100782496
9065.312602074013780.687397925986222
9176.522968018215160.477031981784844
9286.155045447186631.84495455281337
9366.44325204508449-0.443252045084487
9465.236896267700730.763103732299275
9534.52589516893009-1.52589516893009
9676.644469003503840.35553099649616
9734.38419581518341-1.38419581518341
9865.806103335382340.193896664617661
9944.20635533480116-0.206355334801163
10044.83766036264688-0.837660362646882
10164.60635250219621.3936474978038
10266.36441596012699-0.364415960126991
10363.860039309678412.13996069032159
10445.68508287943125-1.68508287943125
10575.466906540455151.53309345954485
10655.27313600955807-0.273136009558073
10776.390000539458240.609999460541762
10844.36343797205832-0.363437972058323
10965.584631645053550.41536835494645
11066.21463908520302-0.21463908520302
11165.118796485889370.881203514110628
11255.11104801913938-0.111048019139377
11355.13483785928872-0.134837859288725
11465.546225254494810.453774745505195
11575.455545899111551.54445410088845
11645.16880954613532-1.16880954613532
11745.26025016385977-1.26025016385977
11885.770624855866192.22937514413381
11965.462173425187240.537826574812759
12034.39110407426271-1.39110407426271
12144.69577398779247-0.69577398779247
12254.56536123338580.434638766614205
12354.189944754948740.810055245051262
12465.850408367230590.149591632769408
12586.77100224874921.22899775125081
12625.21793921444517-3.21793921444517
12743.963440804663280.0365591953367177
12876.237777595890.762222404110002
12954.12981479157730.870185208422704
13065.543482140906350.456517859093654
13166.25703306070132-0.25703306070132
13245.34684331908169-1.34684331908169
13355.52545891625973-0.525458916259732
13465.721216769163960.278783230836039
13565.82297676602020.177023233979801
13665.675957915543380.324042084456618
13765.851114670138710.148885329861289
13855.47707617936013-0.477076179360131
13955.00573897156748-0.00573897156747607
14066.80534861280874-0.805348612808743
14144.59597189217495-0.595971892174951
14264.254735392028461.74526460797154
14334.1963000431308-1.1963000431308
14464.548476627965641.45152337203436
14586.516340492139471.48365950786053
14646.34722071196469-2.34722071196469


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
110.4770267028548330.9540534057096670.522973297145167
120.4078666918514860.8157333837029720.592133308148514
130.2699252323722580.5398504647445160.730074767627742
140.1666546626338640.3333093252677270.833345337366136
150.09910065198563110.1982013039712620.900899348014369
160.1048990179569240.2097980359138470.895100982043076
170.06224348761588580.1244869752317720.937756512384114
180.28589842473570.5717968494713990.7141015752643
190.2481050458498330.4962100916996660.751894954150167
200.4549234223303650.909846844660730.545076577669635
210.8356157552730610.3287684894538780.164384244726939
220.8818224204032150.236355159193570.118177579596785
230.841421267052370.3171574658952590.158578732947629
240.9326406101009320.1347187797981360.0673593898990678
250.9235351372891810.1529297254216370.0764648627108186
260.8967293704680120.2065412590639770.103270629531988
270.8636027791941520.2727944416116950.136397220805848
280.8264618498649640.3470763002700720.173538150135036
290.8015265959403650.3969468081192710.198473404059635
300.7529883073171860.4940233853656280.247011692682814
310.6994350829076450.6011298341847110.300564917092355
320.6769601017767230.6460797964465530.323039898223276
330.6469893311568610.7060213376862770.353010668843139
340.5973122259290270.8053755481419460.402687774070973
350.5414682563685490.9170634872629020.458531743631451
360.5067011034977140.9865977930045720.493298896502286
370.4530234216357170.9060468432714340.546976578364283
380.395397546216910.790795092433820.60460245378309
390.4943931268307790.9887862536615580.505606873169221
400.5080234337981230.9839531324037540.491976566201877
410.4553108596068340.9106217192136670.544689140393166
420.4040092673887030.8080185347774060.595990732611297
430.5106370089130540.9787259821738910.489362991086946
440.623217516760650.75356496647870.37678248323935
450.5701594404205980.8596811191588050.429840559579402
460.6675308137892540.6649383724214920.332469186210746
470.63729521868070.72540956263860.3627047813193
480.6164034473224110.7671931053551780.383596552677589
490.5645161492107340.8709677015785320.435483850789266
500.5374140854465960.9251718291068080.462585914553404
510.5502961896144320.8994076207711360.449703810385568
520.5140315302809320.9719369394381370.485968469719068
530.4821381764502820.9642763529005640.517861823549718
540.4331166008517980.8662332017035970.566883399148202
550.4615832038047970.9231664076095930.538416796195203
560.4275911029865890.8551822059731780.572408897013411
570.4831161472344880.9662322944689770.516883852765512
580.4986589999068890.9973179998137790.501341000093111
590.4476610853101410.8953221706202820.552338914689859
600.4009523025077290.8019046050154580.599047697492271
610.3636327312986620.7272654625973240.636367268701338
620.3318404757266080.6636809514532150.668159524273392
630.2981914802598350.596382960519670.701808519740165
640.2577042361969190.5154084723938390.742295763803081
650.2243469304658450.448693860931690.775653069534155
660.2780294952975170.5560589905950340.721970504702483
670.2477637295762880.4955274591525750.752236270423712
680.2115838181571610.4231676363143220.788416181842839
690.2603980194267450.5207960388534910.739601980573255
700.2258785635985470.4517571271970940.774121436401453
710.1910378310599050.3820756621198090.808962168940095
720.3337834241389050.667566848277810.666216575861095
730.3032991436993240.6065982873986490.696700856300676
740.2970098925464910.5940197850929830.702990107453509
750.2580164896621580.5160329793243150.741983510337842
760.2326432550316030.4652865100632060.767356744968397
770.2028529688968180.4057059377936370.797147031103182
780.1881669546997550.3763339093995090.811833045300245
790.2257883186711880.4515766373423770.774211681328812
800.1925202280571520.3850404561143040.807479771942848
810.1728303121360250.3456606242720510.827169687863975
820.2071448222384330.4142896444768670.792855177761567
830.1844081709955850.368816341991170.815591829004415
840.1792288462616840.3584576925233670.820771153738316
850.1918644561599650.3837289123199290.808135543840035
860.1638507075248860.3277014150497720.836149292475114
870.1717785500832560.3435571001665130.828221449916744
880.1511385304078310.3022770608156610.84886146959217
890.1236817831493960.2473635662987910.876318216850604
900.1083587732410030.2167175464820060.891641226758997
910.09106854070416550.1821370814083310.908931459295835
920.1465933806156870.2931867612313740.853406619384313
930.1226128258436830.2452256516873660.877387174156317
940.1128555618008310.2257111236016630.887144438199169
950.1307654304823170.2615308609646350.869234569517683
960.1103965456328090.2207930912656190.88960345436719
970.1282644993914410.2565289987828820.87173550060856
980.1027616653380590.2055233306761190.89723833466194
990.0817587944805390.1635175889610780.918241205519461
1000.07550806411643670.1510161282328730.924491935883563
1010.08592456466422390.1718491293284480.914075435335776
1020.06812787670457390.1362557534091480.931872123295426
1030.1171355595662670.2342711191325330.882864440433733
1040.170496713933460.340993427866920.82950328606654
1050.2438558169539840.4877116339079680.756144183046016
1060.2065493517759060.4130987035518130.793450648224094
1070.1832226154914730.3664452309829470.816777384508527
1080.1575618942060070.3151237884120140.842438105793993
1090.1305127828797650.2610255657595310.869487217120235
1100.1034040545497130.2068081090994270.896595945450287
1110.1140659171765470.2281318343530940.885934082823453
1120.0951753487619620.1903506975239240.904824651238038
1130.07564784857643060.1512956971528610.92435215142357
1140.06153194526039150.1230638905207830.938468054739608
1150.07835374394749940.1567074878949990.9216462560525
1160.07451786840304680.1490357368060940.925482131596953
1170.07939926266693480.158798525333870.920600737333065
1180.1434018014541010.2868036029082020.856598198545899
1190.1571822144571620.3143644289143240.842817785542838
1200.1466741264916060.2933482529832110.853325873508394
1210.1149493596394270.2298987192788540.885050640360573
1220.1118482785773010.2236965571546020.888151721422699
1230.08357135592994720.1671427118598940.916428644070053
1240.0599762770298750.119952554059750.940023722970125
1250.1003171815214630.2006343630429250.899682818478537
1260.3399179858773270.6798359717546540.660082014122673
1270.2643361499611230.5286722999222460.735663850038877
1280.2630356855935740.5260713711871480.736964314406426
1290.1972158229332370.3944316458664730.802784177066763
1300.1410662613859660.2821325227719330.858933738614034
1310.09277516789383450.1855503357876690.907224832106165
1320.1800048540999090.3600097081998170.819995145900091
1330.1525087805292390.3050175610584780.847491219470761
1340.08938023702765470.1787604740553090.910619762972345
1350.04421777176521230.08843554353042450.955782228234788


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 level10.008OK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/10r1jg1292269393.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/10r1jg1292269393.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/1li441292269393.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/1li441292269393.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/2li441292269393.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/2li441292269393.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/3d9lp1292269393.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/3d9lp1292269393.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/4d9lp1292269393.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/4d9lp1292269393.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/5d9lp1292269393.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/5d9lp1292269393.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/6ojks1292269393.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/6ojks1292269393.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/7hajd1292269393.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/7hajd1292269393.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/8hajd1292269393.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/13/t1292270254hirx8j083vo4k4i/8hajd1292269393.ps (open in new window)


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