Home » date » 2010 » Dec » 14 »

WS 10 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: Tue, 14 Dec 2010 10:17:34 +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/14/t12923218616wijx21vsxo6jl9.htm/, Retrieved Tue, 14 Dec 2010 11:17:41 +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/14/t12923218616wijx21vsxo6jl9.htm/},
    year = {2010},
}
@Manual{R,
    title = {R: A Language and Environment for Statistical Computing},
    author = {{R Development Core Team}},
    organization = {R Foundation for Statistical Computing},
    address = {Vienna, Austria},
    year = {2010},
    note = {{ISBN} 3-900051-07-0},
    url = {http://www.R-project.org},
}
 
Original text written by user:
 
IsPrivate?
No (this computation is public)
 
User-defined keywords:
 
Dataseries X:
» Textbox « » Textfile « » CSV «
1 24 24 13 13 13 1 25 25 12 12 13 1 17 30 15 10 16 0 18 19 12 9 12 1 18 22 10 10 11 1 16 22 12 12 12 1 20 25 15 13 18 1 16 23 9 12 11 1 18 17 12 12 14 1 17 21 11 6 9 0 23 19 11 5 14 1 30 19 11 12 12 0 23 15 15 11 11 1 18 16 7 14 12 1 15 23 11 14 13 0 12 27 11 12 11 0 21 22 10 12 12 1 15 14 14 11 16 0 20 22 10 11 9 1 31 23 6 7 11 0 27 23 11 9 13 1 34 21 15 11 15 1 21 19 11 11 10 1 31 18 12 12 11 0 19 20 14 12 13 1 16 23 15 11 16 0 20 25 9 11 15 1 21 19 13 8 14 1 22 24 13 9 14 0 17 22 16 12 14 1 24 25 13 10 8 0 25 26 12 10 13 1 26 29 14 12 15 1 25 32 11 8 13 0 17 25 9 12 11 0 32 29 16 11 15 0 33 28 12 12 15 0 13 17 10 7 9 1 32 28 13 11 13 0 25 29 16 11 16 0 29 26 14 12 13 1 22 25 15 9 11 0 18 14 5 15 12 0 17 25 8 11 12 1 20 26 11 11 12 1 15 20 16 11 14 1 20 18 17 11 14 1 33 32 9 15 8 1 29 25 9 11 13 0 23 25 13 12 16 1 26 23 10 12 13 0 18 21 6 9 11 0 20 20 12 12 14 1 11 15 8 12 13 0 28 30 14 13 13 1 26 24 12 11 13 1 22 26 11 9 12 1 17 24 16 9 16 0 12 22 8 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
R Framework
error message
The field 'Names of X columns' contains a hard return which cannot be interpreted.
Please, resubmit your request without hard returns in the 'Names of X columns'.


Multiple Linear Regression - Estimated Regression Equation
gender[t] = + 1.08151766603924 -0.00662196627596676CoM[t] -0.00894811157503866PersSt[t] + 0.027465763686152Popularity[t] -0.0223949691901545FindFrie[t] -0.0158619397694246`Liked `[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.081517666039240.3958712.7320.0070510.003526
CoM-0.006621966275966760.007674-0.86290.3895520.194776
PersSt-0.008948111575038660.010337-0.86570.3880580.194029
Popularity0.0274657636861520.0161521.70050.0911150.045558
FindFrie-0.02239496919015450.022279-1.00520.316420.15821
`Liked `-0.01586193976942460.021843-0.72620.4688620.234431


Multiple Linear Regression - Regression Statistics
Multiple R0.210758878378947
R-squared0.0444193048155517
Adjusted R-squared0.0125666149760699
F-TEST (value)1.39452288140808
F-TEST (DF numerator)5
F-TEST (DF denominator)150
p-value0.22948484947114
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation0.48499470453812
Sum Squared Residuals35.2829795145027


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
110.5675509090605560.432449090939444
210.5469100367135530.453089963286447
310.6347466191765850.365253380823415
400.72999931743544-0.72999931743544
510.641690425917290.35830957408271
610.6492140076917940.350785992308206
710.5607124911145650.439287508885435
810.5737305448277240.426269455172276
910.6489867534762050.351013246523795
1010.8060300237539150.193969976246085
1100.727279719591223-0.727279719591223
1210.5558850508672240.444114949132776
1300.786151224803333-0.786151224803333
1410.5075399877790240.492460012220976
1510.5587702205568370.441229779443163
1600.61935749100374-0.61935749100374
1700.561172648939656-0.561172648939656
1810.741299604052830.258700395947170
1900.637775403714051-0.637775403714051
2010.5039786055805390.496021394419461
2100.591281471196008-0.591281471196008
2210.5961731672397680.403826832760232
2310.6696015960799280.330398403920072
2410.6015388996218720.398461100378128
2500.68631391961685-0.68631391961685
2610.6816103972876680.318389602712332
2700.488293666686236-0.488293666686236
2810.7282702719449970.271729728055003
2910.6545127786036830.345487221396317
3000.720731216621586-0.720731216621586
3110.7050974039031030.294902596096897
3200.582751863518823-0.582751863518823
3310.5277032719708860.472296728029114
3410.5463873687627480.453612631237252
3500.54921235540168-0.54921235540168
3600.565297970877544-0.565297970877544
3700.435366092241853-0.435366092241853
3800.81844960228163-0.81844960228163
3910.5235726709329760.476427329067024
4000.595789795039887-0.595789795039887
4100.566405587406951-0.566405587406951
4210.7480820137092220.251917986290778
4300.448109714366642-0.448109714366642
4400.528279621136258-0.528279621136258
4510.5818629017917750.418137098208225
4610.7742663415137520.225733658486248
4710.7865184969701470.213481503029853
4810.3610250256987510.638974974301249
4910.4604198497413840.539580150258616
5000.540033913643364-0.540033913643364
5110.5032527662153590.496747233784641
5200.563170451937875-0.563170451937875
5300.608898486199155-0.608898486199155
5410.6192356255828660.380764374417134
5500.514840138192609-0.514840138192609
5610.5716311512027790.428368848797221
5710.613408907620150.386591092379849
5810.7382960215031230.261703978496877
5900.540647967932934-0.540647967932934
6010.7912492737843740.208750726215626
6100.48736699983499-0.48736699983499
6200.676347128367642-0.676347128367642
6310.7335683206565840.266431679343416
6410.7027460566162720.297253943383728
6510.7005777565847180.299422243415282
6600.521665029531758-0.521665029531758
6710.5224187498661410.477581250133859
6800.612073314674852-0.612073314674852
6910.7889474576377090.211052542362291
7000.46986510206541-0.46986510206541
7100.676576956009456-0.676576956009456
7210.649900044355660.35009995564434
7310.474971247918220.52502875208178
7400.58177468713684-0.58177468713684
7500.585078008817895-0.585078008817895
7610.604894527140680.395105472859320
7710.6556330489045790.344366951095421
7810.6898221133031540.310177886696846
7900.64360764512231-0.64360764512231
8000.393973435307590-0.393973435307590
8100.438687090604151-0.438687090604151
8210.8700119755282850.129988024471715
8300.656827248521837-0.656827248521837
8410.5857402188708160.414259781129184
8510.6571703421712950.342829657828705
8600.611605430271883-0.611605430271883
8710.5520332876823530.447966712317647
8810.7112768890352210.288723110964779
8910.6096820591314880.390317940868512
9010.6415521085569380.358447891443062
9110.641613640292080.35838635970792
9210.6356677625822880.364332237417712
9310.7403698612338970.259630138766103
9410.7208074997053340.279192500294666
9510.6606911896290870.339308810370913
9610.4213338101990270.578666189800973
9710.5450824765640710.454917523435929
9800.471542413283351-0.471542413283351
9900.679668848930241-0.679668848930241
10010.6568784802528760.343121519747124
10100.662722397042052-0.662722397042052
10210.7449575441292110.255042455870789
10300.555592316113452-0.555592316113452
10410.6463804216396320.353619578360368
10500.477544175340046-0.477544175340046
10610.6034456681877380.396554331812262
10700.598427330164544-0.598427330164544
10800.652823289463361-0.652823289463361
10910.4928193153049450.507180684695055
11010.6597547943389890.340245205661011
11110.7262650942753120.273734905724688
11210.6792607956715410.320739204328459
11310.5548802497063070.445119750293693
11400.480636568796621-0.480636568796621
11510.6518805225790480.348119477420952
11610.7586962636627460.241303736337254
11710.6806429493445370.319357050655463
11810.5695747418020540.430425258197946
11900.612823959041548-0.612823959041548
12010.7805856433257340.219414356674266
12110.5114740600346470.488525939965353
12210.784524994681380.215475005318620
12310.4951697897564240.504830210243576
12410.6470791120749870.352920887925013
12500.734331618794769-0.734331618794769
12610.5999503746241170.400049625375883
12710.7022512696346710.297748730365329
12810.5889679796684250.411032020331575
12900.675308420250516-0.675308420250516
13000.497597420127003-0.497597420127003
13110.6380012825528260.361998717447174
13200.791832997621212-0.791832997621212
13300.515264643390786-0.515264643390786
13410.6424914291796730.357508570820327
13500.720466257281799-0.720466257281799
13600.531339958862547-0.531339958862547
13710.7084170268885860.291582973111414
13810.5075893682841390.492410631715861
13900.796214679485656-0.796214679485656
14010.6225482688774540.377451731122546
14100.554091397673951-0.554091397673951
14210.4896115829502920.510388417049708
14300.624135921039856-0.624135921039856
14410.6551508101392470.344849189860753
14510.5912941249674970.408705875032503
14600.42519945189715-0.42519945189715
14700.381453244543720-0.381453244543720
14800.461971999911925-0.461971999911925
14910.829659727302020.170340272697980
15010.6896556686224050.310344331377595
15100.620932489394654-0.620932489394654
15210.5982694848970250.401730515102975
15310.3808916467269530.619108353273047
15410.6884621912054490.311537808794551
15510.6821564160003080.317843583999692
15610.6601074657922490.339892534207751


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
90.2693441198968370.5386882397936730.730655880103163
100.4014817000126370.8029634000252750.598518299987363
110.2815724641029140.5631449282058280.718427535897086
120.2030884887743190.4061769775486370.796911511225681
130.1945374100426270.3890748200852540.805462589957373
140.1275644349698830.2551288699397660.872435565030117
150.0903318775574980.1806637551149960.909668122442502
160.4511026365342220.9022052730684440.548897363465778
170.6513025329803790.6973949340392420.348697467019621
180.6164312333822050.767137533235590.383568766617795
190.6282835927424340.7434328145151330.371716407257567
200.5756730377126680.8486539245746630.424326962287332
210.6457351444651540.7085297110696920.354264855534846
220.601325966870150.79734806625970.39867403312985
230.5931719579010730.8136560841978540.406828042098927
240.5479522423778930.9040955152442150.452047757622107
250.6029896486300810.7940207027398380.397010351369919
260.5599827080032520.8800345839934970.440017291996748
270.6759198548665950.648160290266810.324080145133405
280.6536867397872630.6926265204254730.346313260212737
290.621628741866150.75674251626770.37837125813385
300.6693606320920610.6612787358158780.330639367907939
310.6593071777059080.6813856445881840.340692822294092
320.7043964517419160.5912070965161690.295603548258084
330.6710495610228120.6579008779543760.328950438977188
340.6439034908750720.7121930182498560.356096509124928
350.6721956269967520.6556087460064960.327804373003248
360.7291067541045820.5417864917908370.270893245895418
370.7557493769874440.4885012460251120.244250623012556
380.7875364356251110.4249271287497780.212463564374889
390.7737250081289870.4525499837420250.226274991871012
400.7898618658933060.4202762682133890.210138134106694
410.8030435870189170.3939128259621660.196956412981083
420.7977147460958720.4045705078082570.202285253904128
430.8092657683896230.3814684632207530.190734231610377
440.8107266609642440.3785466780715110.189273339035756
450.8019517104109650.396096579178070.198048289589035
460.7775122058109990.4449755883780020.222487794189001
470.7461982803711630.5076034392576740.253801719628837
480.752453014538010.4950939709239790.247546985461989
490.7520595531435480.4958808937129030.247940446856452
500.7626453474759860.4747093050480270.237354652524014
510.7578905115264140.4842189769471710.242109488473586
520.7626103579589580.4747792840820830.237389642041042
530.7777472315634320.4445055368731360.222252768436568
540.7748943412032440.4502113175935130.225105658796756
550.7872601668685250.425479666262950.212739833131475
560.7767508499584690.4464983000830630.223249150041531
570.7639348551539710.4721302896920570.236065144846029
580.7420129488874430.5159741022251140.257987051112557
590.7454186670567030.5091626658865950.254581332943297
600.7167971853846980.5664056292306030.283202814615302
610.7150826972176860.5698346055646290.284917302782314
620.749185623370090.5016287532598210.250814376629911
630.7240181979325670.5519636041348650.275981802067433
640.6996330928238950.6007338143522110.300366907176105
650.6808434331389980.6383131337220030.319156566861002
660.6877603427896260.6244793144207490.312239657210374
670.6853354730243360.6293290539513290.314664526975664
680.7092096203721030.5815807592557940.290790379627897
690.678376191720750.64324761655850.32162380827925
700.6801777798204180.6396444403591650.319822220179582
710.7168598543630990.5662802912738020.283140145636901
720.6958233869076080.6083532261847840.304176613092392
730.7021008712480710.5957982575038580.297899128751929
740.7173259174719520.5653481650560970.282674082528048
750.736334572761440.527330854477120.26366542723856
760.7234833456146070.5530333087707860.276516654385393
770.70116323132650.5976735373469990.298836768673500
780.6749054366892880.6501891266214240.325094563310712
790.7088359710482640.5823280579034730.291164028951736
800.6936743018119220.6126513963761560.306325698188078
810.689205410165960.621589179668080.31079458983404
820.6494447483635070.7011105032729870.350555251636493
830.683339807899510.633320384200980.31666019210049
840.6664115467770120.6671769064459760.333588453222988
850.6451110262224060.7097779475551880.354888973777594
860.6690896275718910.6618207448562170.330910372428109
870.6545416030532210.6909167938935590.345458396946779
880.6220490244603720.7559019510792560.377950975539628
890.6055858175950090.7888283648099830.394414182404991
900.5813894152460390.8372211695079220.418610584753961
910.5665242311933130.8669515376133730.433475768806687
920.5380818799424040.9238362401151930.461918120057596
930.503768405117880.992463189764240.49623159488212
940.4697086492801650.939417298560330.530291350719835
950.4406542148926850.881308429785370.559345785107315
960.4566198553750230.9132397107500460.543380144624977
970.4550789952430630.9101579904861270.544921004756937
980.4513085338208530.9026170676417070.548691466179147
990.4955108055617540.9910216111235090.504489194438246
1000.4727103203916630.9454206407833270.527289679608337
1010.5077919315699470.9844161368601060.492208068430053
1020.4697538653087930.9395077306175850.530246134691207
1030.482560139246440.965120278492880.51743986075356
1040.4524526075166010.9049052150332030.547547392483399
1050.4664977302223330.9329954604446650.533502269777667
1060.4578511639164540.9157023278329080.542148836083546
1070.5035198082932170.9929603834135670.496480191706783
1080.5373793808479810.9252412383040380.462620619152019
1090.5225924453759670.9548151092480660.477407554624033
1100.4805942903818740.9611885807637480.519405709618126
1110.4352981554529410.8705963109058830.564701844547059
1120.4136941127451100.8273882254902210.58630588725489
1130.3943692875189010.7887385750378030.605630712481099
1140.4072167290216890.8144334580433770.592783270978311
1150.3649468580711380.7298937161422760.635053141928862
1160.324184064199370.648368128398740.67581593580063
1170.2923346697826950.5846693395653890.707665330217305
1180.2717406935113280.5434813870226560.728259306488672
1190.2878770757196860.5757541514393710.712122924280314
1200.2613345134950970.5226690269901930.738665486504903
1210.2578776329725590.5157552659451190.74212236702744
1220.2238361260218640.4476722520437280.776163873978136
1230.2135833826511050.427166765302210.786416617348895
1240.1916306815905250.3832613631810490.808369318409475
1250.2243731845958410.4487463691916820.775626815404159
1260.2097781698627930.4195563397255870.790221830137207
1270.1826602073890460.3653204147780930.817339792610954
1280.1725834199811150.3451668399622310.827416580018885
1290.2259309942677030.4518619885354060.774069005732297
1300.2877933332405050.5755866664810090.712206666759495
1310.2898542962027970.5797085924055940.710145703797203
1320.3790585046078660.7581170092157330.620941495392134
1330.4136650635689390.8273301271378780.586334936431061
1340.4257399168634690.8514798337269370.574260083136531
1350.4524950473766410.9049900947532810.547504952623359
1360.4492928804259790.8985857608519570.550707119574021
1370.3841028269697230.7682056539394450.615897173030277
1380.3658768959065590.7317537918131180.634123104093441
1390.4826969709117810.9653939418235610.517303029088219
1400.4188888841059430.8377777682118850.581111115894057
1410.589722195540180.8205556089196390.410277804459820
1420.5663211210422140.8673577579155720.433678878957786
1430.7178289094770040.5643421810459910.282171090522996
1440.6066679801308460.7866640397383080.393332019869154
1450.6238476318125560.7523047363748870.376152368187444
1460.5428773409335630.9142453181328730.457122659066437
1470.513409335675710.973181328648580.48659066432429


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 level00OK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/1067pw1292321841.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/1067pw1292321841.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/1z6sk1292321841.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/1z6sk1292321841.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/2z6sk1292321841.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/2z6sk1292321841.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/3sx951292321841.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/3sx951292321841.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/4sx951292321841.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/4sx951292321841.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/5sx951292321841.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/5sx951292321841.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/63p981292321841.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/63p981292321841.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/7vy8b1292321841.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/7vy8b1292321841.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/8vy8b1292321841.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/14/t12923218616wijx21vsxo6jl9/8vy8b1292321841.ps (open in new window)


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