Home » date » 2010 » Dec » 02 »

WS7 days

*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 21:30: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/02/t1291325377e93hmn68q3oimx3.htm/, Retrieved Thu, 02 Dec 2010 22:29:47 +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/t1291325377e93hmn68q3oimx3.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 «
20 10 11 4 25 25 1 16 11 11 11 23 21 2 18 16 12 7 17 22 2 17 11 13 7 21 25 3 23 13 14 12 19 24 3 30 12 16 10 19 18 4 23 8 11 10 15 22 4 18 12 10 8 16 15 4 15 11 11 8 23 22 6 12 4 15 4 27 28 7 21 9 9 9 22 20 7 15 8 11 8 14 12 8 20 8 17 7 22 24 8 31 14 17 11 23 20 11 27 15 11 9 23 21 12 34 16 18 11 21 20 13 21 9 14 13 19 21 13 31 14 10 8 18 23 13 19 11 11 8 20 28 13 16 8 15 9 23 24 13 20 9 15 6 25 24 13 21 9 13 9 19 24 13 22 9 16 9 24 23 13 17 9 13 6 22 23 13 24 10 9 6 25 29 13 25 16 18 16 26 24 13 26 11 18 5 29 18 13 25 8 12 7 32 25 13 17 9 17 9 25 21 13 32 16 9 6 29 26 13 33 11 9 6 28 22 13 13 16 12 5 17 22 13 32 12 18 12 28 22 13 25 12 12 7 29 23 13 29 14 18 10 26 30 13 22 9 14 9 25 23 13 18 10 15 8 14 17 13 17 9 16 5 25 23 13 20 10 10 8 26 23 14 15 12 11 8 20 25 14 20 14 14 10 18 24 14 33 14 9 6 32 24 14 29 10 12 8 25 23 14 23 14 17 7 25 21 14 26 16 5 4 23 24 14 18 9 12 8 21 24 14 20 10 12 8 20 28 14 11 6 6 4 15 16 14 28 8 24 20 30 20 14 26 13 12 8 24 29 14 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 time11 seconds
R Server'George Udny Yule' @ 72.249.76.132


Multiple Linear Regression - Estimated Regression Equation
Org[t] = + 17.4786370540133 -0.0540349079271798concern[t] + 0.198638591131809doubts[t] -0.146651984124796Par_Crit[t] -0.257571601145397Par_Stan[t] + 0.410140826539548Pers_Stand[t] -0.0822244901852577Days[t] + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)17.47863705401332.2750187.682900
concern-0.05403490792717980.063984-0.84450.3997710.199886
doubts0.1986385911318090.1139471.74330.0833940.041697
Par_Crit-0.1466519841247960.10841-1.35270.1782270.089114
Par_Stan-0.2575716011453970.133592-1.9280.0557910.027895
Pers_Stand0.4101408265395480.0772195.311400
Days-0.08222449018525770.069938-1.17570.2416390.120819


Multiple Linear Regression - Regression Statistics
Multiple R0.47825847489625
R-squared0.228731168810087
Adjusted R-squared0.197035189446118
F-TEST (value)7.21640956991855
F-TEST (DF numerator)6
F-TEST (DF denominator)146
p-value9.27772276893002e-07
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation3.5095232926118
Sum Squared Residuals1798.24604624218


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
12525.9121627501368-0.912162750136833
22123.6214336216953-2.62143362169528
32222.9293462227194-0.929346222719448
42523.40187500683571.59812499316427
52421.22015109860542.77984890139461
61820.7828828958393-2.78288289583926
72219.45926950126812.54073049873192
81521.5959344183863-6.59593441838635
92224.1192853723176-2.11928537231761
102824.89293724223183.10706275776818
112022.9411657928703-2.9411657928703
121219.6676531796957-7.66765317969573
132422.05626494877281.94373505122716
142021.7868934597669-1.7868934597669
152123.5145022994617-2.51450229946174
162020.8906833006746-0.89068330067457
172119.45385004693451.54614995306546
182321.37101903900841.62898096099159
192822.09715182969345.90284817030656
202422.04958372205361.95041627794639
212423.6250791379920.374920862008009
222420.63078843564093.36921156435908
232322.18750170803710.812498291962904
242322.85006535040450.149934649595523
252924.48749000216394.51250999783614
262422.13984359898991.86015640101005
271825.1563258276217-7.15632582762173
282526.2096361442301-1.20963614423011
292122.7211650900877-1.72116509008775
302626.8876055916955-0.887605591695466
312225.4302369015697-3.43023690156969
322222.8101945726083-0.810194572608312
332222.8176129366331-0.817612936633136
342325.7737680291387-2.77376802913870
353023.071856391896.92814360811001
362322.89094650282620.109053497173763
371718.9050952507523-1.90509525075233
382323.8981034787941-0.89810347879413
392324.3697507838113-1.36975078381128
402522.42970556234872.57029443765129
412420.78142739723223.21857260276785
422427.5844914909381-3.58449149093805
432323.1799918176775-0.179991817677518
442123.8230673102893-2.82306731028925
452425.7704967286260-1.77049672862597
462421.93517390758652.06482609241351
472821.61560185632446.3843981436756
481621.1668558397744-5.1668558397744
492020.0367706527965-0.0367706527965078
502923.52787148831495.47212851168506
512723.88615250952213.11384749047793
522223.1606074478565-1.16060744785645
532823.95356883444584.04643116555419
541620.2432828259992-4.24328282599918
552522.87983520380172.12016479619833
562423.48839698253610.511603017463852
572823.58952039538394.41047960461607
582424.2069625969009-0.206962596900906
592322.58295240643240.417047593567626
603026.96992163367193.03007836632806
612421.50864983388042.49135016611957
622124.1131074845865-3.11310748458655
632523.12198347073441.87801652926562
642523.92937207409351.07062792590652
652220.96139252160351.03860747839652
662322.49644206299380.503557937006159
672622.96784792799263.03215207200742
682321.61805192188721.38194807811276
692523.13642071005841.86357928994160
702121.2890481521723-0.28904815217234
712523.40258364067691.59741635932308
722422.06380123397441.93619876602557
732923.42619141401295.57380858598708
742223.636707554532-1.63670755453199
752723.47251146298173.52748853701827
762619.68089783178726.31910216821285
772221.23760233962600.762397660374026
782422.00282868759801.99717131240197
792722.95055993991014.04944006008985
802421.18449573361952.81550426638054
812424.6951052246397-0.695105224639718
822924.10403572192484.89596427807521
832222.0728745470201-0.0728745470200756
842120.45011241522260.549887584777446
852420.31554685486453.68445314513546
862421.60769482163182.39230517836819
872321.76595488480111.23404511519892
882022.1563274729098-2.15632747290976
892721.26597431093755.73402568906246
902623.34608005533952.65391994466053
912521.82564120250513.17435879749494
922119.97847250502861.02152749497138
932120.57939016044500.420609839554965
941920.2117004425251-1.21170044252511
952121.3999224967553-0.399922496755288
962121.0659650375751-0.0659650375750816
971619.5463582132872-3.54635821328719
982220.45253820104851.54746179895153
992921.55066231816317.44933768183694
1001521.5000280284170-6.50002802841704
1011720.5659857217085-3.56598572170846
1021519.7999896597877-4.7999896597877
1032121.4186946177432-0.41869461774322
1042120.70780205348520.292197946514808
1051919.0643977107181-0.064397710718112
1062418.01997145574245.98002854425756
1072022.1431962604890-2.14319626048896
1081724.9200992724603-7.9200992724603
1092324.5916940901740-1.59169409017404
1102422.14176999087941.85823000912059
1111421.8636286510571-7.86362865105707
1121922.6025463651619-3.60254636516190
1132421.9338378200342.06616217996599
1141320.2312510420191-7.2312510420191
1152225.2234195998134-3.22341959981341
1161620.836701055805-4.8367010558050
1171922.9578738052682-3.9578738052682
1182522.55465635999522.44534364000478
1192523.76116342593371.23883657406633
1202321.07999890244551.92000109755452
1212423.22124878868070.778751211319337
1222623.19033328681292.80966671318710
1232621.17181447839704.82818552160297
1242523.90407691023411.09592308976591
1251822.0162446992728-4.01624469927276
1262119.58141713981681.41858286018318
1272623.31773480522752.68226519477253
1282321.67330255872011.32669744127991
1292319.50988119131273.49011880868727
1302222.2486716151786-0.248671615178583
1312022.0134673703991-2.01346737039914
1321321.7157436447854-8.71574364478544
1332421.12187617231022.87812382768982
1341521.2247490102913-6.22474901029129
1351422.8714915215012-8.87149152150118
1362223.7975757925807-1.79757579258068
1371017.3423519415139-7.34235194151386
1382424.0597530037297-0.0597530037296909
1392221.47080802642480.529191973575171
1402425.4427777530368-1.44277775303677
1411921.4713294379957-2.47132943799568
1422021.8202052260760-1.82020522607604
1431316.8630005794341-3.86300057943414
1442019.89068523673970.109314763260257
1452222.9584889742194-0.958488974219369
1462423.01798705843050.982012941569469
1472923.05946083671885.94053916328116
1481220.6272449157283-8.62724491572833
1492020.5003829337775-0.5003829337775
1502121.044071439489-0.0440714394890285
1512423.27174530660560.728254693394364
1522221.39305888098260.606941119017426
1532017.23769431677882.76230568322118


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
100.6851607088460540.6296785823078920.314839291153946
110.59484795685710.81030408628580.4051520431429
120.6959911687181860.6080176625636270.304008831281814
130.5906763110586930.8186473778826140.409323688941307
140.4820274433464490.9640548866928970.517972556653551
150.4824800768236770.9649601536473530.517519923176323
160.3832293431412820.7664586862825640.616770656858718
170.3611350618792260.7222701237584510.638864938120774
180.5109364998606750.978127000278650.489063500139325
190.7237209431807910.5525581136384190.276279056819209
200.6505164344652660.6989671310694680.349483565534734
210.58431000299230.83137999401540.4156899970077
220.5491591247592060.9016817504815870.450840875240794
230.4781285769052570.9562571538105130.521871423094743
240.4071306568219650.814261313643930.592869343178035
250.4011464856157550.802292971231510.598853514384245
260.3380995993055960.6761991986111920.661900400694404
270.6267585431368070.7464829137263860.373241456863193
280.5920591483335090.8158817033329820.407940851666491
290.557990614521780.884018770956440.44200938547822
300.4956627178356210.9913254356712410.504337282164379
310.4886188431568970.9772376863137950.511381156843103
320.430429779617180.860859559234360.569570220382820
330.3763587688127610.7527175376255220.623641231187239
340.3509771652655430.7019543305310860.649022834734457
350.5265058945246730.9469882109506540.473494105475327
360.4691553017742690.9383106035485380.530844698225731
370.4481583176208890.8963166352417780.551841682379111
380.3990508008654590.7981016017309170.600949199134541
390.3584301210200740.7168602420401490.641569878979926
400.325382615395090.650765230790180.67461738460491
410.297278772704950.59455754540990.70272122729505
420.2862955812427680.5725911624855360.713704418757232
430.2443099055015910.4886198110031820.755690094498409
440.2405273130001210.4810546260002410.75947268699988
450.2163258879536870.4326517759073730.783674112046313
460.1826427491550400.3652854983100810.81735725084496
470.2443724538027710.4887449076055430.755627546197229
480.3370891457791050.6741782915582110.662910854220895
490.3292443557965320.6584887115930640.670755644203468
500.3860004744581330.7720009489162650.613999525541868
510.362593077986120.725186155972240.63740692201388
520.3286587028285580.6573174056571160.671341297171442
530.3291760829134740.6583521658269480.670823917086526
540.4029712703202940.8059425406405880.597028729679706
550.3579320482768860.7158640965537710.642067951723114
560.3138167656458070.6276335312916130.686183234354193
570.3200495038197370.6400990076394730.679950496180263
580.2832123625111010.5664247250222020.716787637488899
590.2441986628705560.4883973257411130.755801337129444
600.2299834152919750.459966830583950.770016584708025
610.2007300283190710.4014600566381420.799269971680929
620.2188404304588070.4376808609176150.781159569541193
630.1885595521514590.3771191043029180.811440447848541
640.1576794783922700.3153589567845390.84232052160773
650.1305957414896300.2611914829792590.86940425851037
660.107855988487030.215711976974060.89214401151297
670.09294255473603860.1858851094720770.907057445263961
680.07546174957304670.1509234991460930.924538250426953
690.06099255803141370.1219851160628270.939007441968586
700.05003414043383960.1000682808676790.94996585956616
710.03955482828708490.07910965657416990.960445171712915
720.03060776038268470.06121552076536950.969392239617315
730.03696196275362710.07392392550725420.963038037246373
740.03281617621971530.06563235243943060.967183823780285
750.02808818148838560.05617636297677130.971911818511614
760.03742105076258040.07484210152516090.96257894923742
770.02868644895854220.05737289791708440.971313551041458
780.02212257946837450.0442451589367490.977877420531626
790.02159944889790330.04319889779580660.978400551102097
800.01759357382473550.03518714764947110.982406426175265
810.01366651502367700.02733303004735390.986333484976323
820.01562717813913580.03125435627827160.984372821860864
830.01256662002264730.02513324004529460.987433379977353
840.009368584824959380.01873716964991880.99063141517504
850.008431437638150890.01686287527630180.99156856236185
860.006988087686419230.01397617537283850.99301191231358
870.005182155771806550.01036431154361310.994817844228193
880.004582483473141760.009164966946283530.995417516526858
890.007562145680723260.01512429136144650.992437854319277
900.006685171343573540.01337034268714710.993314828656426
910.006381168768815070.01276233753763010.993618831231185
920.005188987293419440.01037797458683890.99481101270658
930.003952736404912870.007905472809825730.996047263595087
940.003252243414790130.006504486829580250.99674775658521
950.002553714795503560.005107429591007110.997446285204497
960.001878646489081710.003757292978163430.998121353510918
970.002148193485055470.004296386970110940.997851806514945
980.001751382602909240.003502765205818480.99824861739709
990.008467369590587560.01693473918117510.991532630409412
1000.01891929197095650.0378385839419130.981080708029043
1010.01975359956453080.03950719912906160.980246400435469
1020.02557749675292590.05115499350585180.974422503247074
1030.02067819575100340.04135639150200670.979321804248997
1040.01544288923014540.03088577846029080.984557110769855
1050.01149839391439130.02299678782878260.988501606085609
1060.04101343109526070.08202686219052140.95898656890474
1070.04223305376451980.08446610752903960.95776694623548
1080.09816619076555890.1963323815311180.901833809234441
1090.0860856849508960.1721713699017920.913914315049104
1100.07513127954130840.1502625590826170.924868720458692
1110.1623978407415280.3247956814830570.837602159258472
1120.1523449602343520.3046899204687030.847655039765648
1130.1545948019642000.3091896039284010.8454051980358
1140.2201617996224570.4403235992449140.779838200377543
1150.2022151388355160.4044302776710310.797784861164484
1160.2221029871469340.4442059742938680.777897012853066
1170.2091608969995970.4183217939991940.790839103000403
1180.2161475361578730.4322950723157450.783852463842127
1190.2169283133982420.4338566267964850.783071686601758
1200.1821901977470220.3643803954940440.817809802252978
1210.1456457356449100.2912914712898200.85435426435509
1220.1490424340534550.298084868106910.850957565946545
1230.2163590438263980.4327180876527960.783640956173602
1240.1947123921420030.3894247842840050.805287607857997
1250.1718855145896120.3437710291792240.828114485410388
1260.1583848046163600.3167696092327190.84161519538364
1270.1432991922252360.2865983844504720.856700807774764
1280.1194418530580680.2388837061161360.880558146941932
1290.1935225396156230.3870450792312460.806477460384377
1300.1482298825649120.2964597651298240.851770117435088
1310.1123699283540940.2247398567081880.887630071645906
1320.2278047291782510.4556094583565020.772195270821749
1330.3207412340957040.6414824681914070.679258765904296
1340.2864684163008240.5729368326016490.713531583699176
1350.4899136531709880.9798273063419770.510086346829012
1360.4320687229480020.8641374458960040.567931277051998
1370.6776115808644940.6447768382710120.322388419135506
1380.6137631148183540.7724737703632930.386236885181647
1390.5027555356380050.994488928723990.497244464361995
1400.4401131571392380.8802263142784750.559886842860762
1410.4617258021900970.9234516043801940.538274197809903
1420.3263615147346420.6527230294692850.673638485265358
1430.2139580000365000.4279160000730010.7860419999635


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level70.0522388059701493NOK
5% type I error level270.201492537313433NOK
10% type I error level370.276119402985075NOK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/02/t1291325377e93hmn68q3oimx3/10ykn81291325413.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/02/t1291325377e93hmn68q3oimx3/10ykn81291325413.ps (open in new window)


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


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


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


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


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


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


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


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


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


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