Home » date » 2010 » Dec » 21 »

Multiple Regressions

*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, 21 Dec 2010 15:03:21 +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/21/t1292943801aduq0viqpc034dz.htm/, Retrieved Tue, 21 Dec 2010 16:03:36 +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/21/t1292943801aduq0viqpc034dz.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 «
143827 829461 4.93 5.01 639.98 3536.15 0.94 109.57 9113 145191 837669 4.92 5.02 597.33 3240.92 0.92 107.08 9140 146832 854793 4.83 4.94 558.36 3121.58 0.91 110.33 9309 148577 850092 5.02 5.10 593.09 3302.70 0.89 110.36 9395 149873 848783 5.22 5.26 585.15 3292.49 0.87 106.50 10027 151847 846150 5.17 5.21 573.50 3162.62 0.85 104.30 10202 153252 828543 5.17 5.25 548.72 3051.60 0.86 107.21 10003 154292 830389 4.98 5.06 523.63 2848.11 0.90 109.34 9745 155657 848989 4.98 5.04 453.87 2577.68 0.91 108.20 9966 156523 841106 4.77 4.82 460.33 2680.55 0.91 109.86 10035 156416 854616 4.62 4.67 492.67 2775.70 0.89 108.68 9999 156693 832714 4.89 4.95 506.78 2879.30 0.89 113.38 9943 160312 839290 4.97 5.02 500.92 2790.11 0.88 117.12 10258 160438 840572 5.03 5.07 494.91 2764.18 0.87 116.23 10926 160882 869186 5.27 5.31 531.21 2868.37 0.88 114.75 10807 161668 856979 5.25 5.29 511.28 2740.50 0.89 115.81 10992 164391 872126 5.30 5.31 484.55 2622.87 0.92 115.86 11034 168556 868281 5.16 5.17 439.66 2376.70 0.96 11 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 time17 seconds
R Server'George Udny Yule' @ 72.249.76.132


Multiple Linear Regression - Estimated Regression Equation
SpaarNL[t] = + 25533.6968586138 + 0.0675790252249236Leningen[t] + 11377.5610545139`10jNL`[t] -12780.5380104956`10JEUR`[t] -284.080217654409AEX[t] + 48.3210098962368EURO[t] + 36746.7729427624USD[t] + 108.679230765155YEN[t] + 4.30611868642121GOLD[t] + e[t]


Multiple Linear Regression - Ordinary Least Squares
VariableParameterS.D.T-STAT
H0: parameter = 0
2-tail p-value1-tail p-value
(Intercept)25533.696858613811382.2198032.24330.02690.01345
Leningen0.06757902522492360.0139234.85364e-062e-06
`10jNL`11377.56105451399101.4742731.25010.2139480.106974
`10JEUR`-12780.53801049569790.550389-1.30540.1945070.097254
AEX-284.08021765440952.322441-5.429400
EURO48.32100989623689.8604034.90053e-062e-06
USD36746.772942762412892.8410212.85020.0052260.002613
YEN108.679230765155103.5324061.04970.2961720.148086
GOLD4.306118686421210.33558212.831800


Multiple Linear Regression - Regression Statistics
Multiple R0.99094578367694
R-squared0.981973546187107
Adjusted R-squared0.980650503705427
F-TEST (value)742.208628811386
F-TEST (DF numerator)8
F-TEST (DF denominator)109
p-value0
Multiple Linear Regression - Residual Statistics
Residual Standard Deviation6230.06816412887
Sum Squared Residuals4230698676.93644


Multiple Linear Regression - Actuals, Interpolation, and Residuals
Time or IndexActualsInterpolation
Forecast
Residuals
Prediction Error
1143827148405.034187474-4578.03418747407
2145191145679.069828239-488.069828238617
3146832152852.206191663-6020.2061916633
4148577151175.814191128-2598.81419112809
5149873154647.248513677-4774.24851367682
6151847151353.087772094493.912227906421
7153252151153.7183016912098.28169830898
8154292149430.1442192004861.85578079977
9155657158887.935761980-3230.93576198033
10156523162390.794641405-5867.79464140506
11156416157906.626444405-1490.62644440506
12156693157187.235968012-494.235968011862
13160312156397.5820441843914.41795581642
14160438159394.4984764821043.50152351770
15160882155408.1386992785473.8613007224
16161668155373.4719509246294.5280490762
17164391159908.5166969804482.48330301968
18168556161379.6530546367176.34694536353
19169738168974.221176522763.778823477707
20170387167677.7835046002709.21649539962
21171294175078.093797074-3784.09379707369
22172202171678.388659177523.611340822628
23172651173232.578610673-581.578610672689
24172770175835.553102918-3065.55310291823
25178366180541.014773351-2175.01477335128
26180014187979.615865739-7965.61586573948
27181067187509.449837263-6442.44983726338
28182586185774.608789225-3188.60878922513
29184957193027.032894278-8070.03289427842
30186417192910.901922809-6493.90192280897
31188599187153.6150269601445.38497303974
32189490186135.0489101833354.95108981702
33190264191245.112206034-981.112206034347
34191221190655.421919650565.578080350328
35191110192549.306265688-1439.30626568817
36190674197794.962450050-7120.96245005026
37195438196893.900191873-1455.90019187305
38196393197757.471173246-1364.47117324613
39197172200766.954084996-3594.95408499601
40198760201006.215642499-2246.21564249907
41200945201102.261853487-157.261853487097
42203845200578.5834183563266.41658164397
43204613205330.253471913-717.253471913398
44205487207062.937869157-1575.93786915733
45206100209412.043690639-3312.04369063904
46206315211419.143733932-5104.14373393160
47206291214356.258985778-8065.25898577801
48207801213981.955295070-6180.95529506965
49211653211394.35096377258.649036230201
50211325210170.3387253191154.66127468050
51211893213171.05155761-1278.05155760984
52212056217290.338562238-5234.33856223824
53214696217166.338510297-2470.33851029655
54217455215091.7643139452363.23568605471
55218884204505.99565320814378.0043467924
56219816207936.75301249011879.2469875098
57219984214051.9673789325932.03262106766
58219062215925.2049730453136.79502695512
59218550213551.0719488484998.92805115239
60218179214664.5363178343514.46368216638
61222218218164.875305984053.12469401983
62222196217915.6076144374280.39238556332
63223393219437.0209077343955.97909226588
64223292226013.351848435-2721.35184843492
65226236234517.464429847-8281.46442984735
66228831225355.1723205193475.82767948059
67228745228737.0552287727.9447712278511
68229140227118.3437817942021.65621820594
69229270222040.660704027229.33929598014
70229359226030.8711086603328.12889133956
71230006232235.157747131-2229.15774713095
72228810231527.215706028-2717.21570602789
73232677235440.963964112-2763.96396411195
74232961238042.854798049-5081.85479804878
75234629234914.213927539-285.213927539195
76235660236847.453330115-1187.45333011472
77240024237893.4191685602130.58083144033
78243554234816.3518493728737.64815062765
79244368234789.6085854499578.39141455077
80244356238215.5443977496140.45560225092
81245126239516.6621352245609.3378647765
82246321247616.453612925-1295.45361292538
83246797257402.570039116-10605.5700391164
84246735252551.17700358-5816.17700357996
85251083263344.966527308-12261.9665273077
86251786264323.896133391-12537.8961333906
87252732262492.158232545-9760.15823254543
88255051259445.105938424-4394.10593842411
89259022255824.0633815293197.93661847102
90261698260074.5779465311623.42205346914
91263891269844.441866128-5953.4418661281
92265247259510.7360482955736.26395170457
93262228272357.708296821-10129.7082968209
94263429274445.963866315-11016.9638663153
95264305266173.74335452-1868.7433545199
96266371262486.2198987133884.78010128693
97273248265093.4236654678154.57633453305
98275472274184.4214597991287.57854020126
99278146271574.7983248556571.20167514535
100279506272676.1239571356829.87604286464
101283991274168.7360754949822.26392450577
102286794274542.79002525212251.2099747484
103288703273847.66617239614855.3338276039
104289285275983.08391902413301.9160809759
105288869275727.90184789113141.0981521087
106286942281681.1080255875260.89197441264
107285833287671.335307778-1838.33530777794
108284095286655.58611009-2560.58611008991
109289229283076.7808704426152.21912955754
110289389284237.0149619535151.98503804671
111290793287584.4370108733208.56298912739
112291454286771.9952448014682.00475519878
113294733303981.131553162-9248.13155316167
114293853306523.596047131-12670.5960471305
115294056294589.167216605-533.167216605448
116293982297552.923745298-3570.92374529837
117293075297171.963347249-4096.96334724889
118292391305102.186121918-12711.1861219176


Goldfeld-Quandt test for Heteroskedasticity
p-valuesAlternative Hypothesis
breakpoint indexgreater2-sidedless
120.001318843799331470.002637687598662940.998681156200669
130.0001050470169399760.0002100940338799510.99989495298306
147.63941713092074e-061.52788342618415e-050.999992360582869
150.0001232043981417720.0002464087962835440.999876795601858
161.92070323985524e-053.84140647971049e-050.999980792967601
173.53242870016739e-067.06485740033479e-060.9999964675713
181.5984649228807e-063.1969298457614e-060.999998401535077
192.92597683812326e-065.85195367624652e-060.999997074023162
208.84916648589e-071.769833297178e-060.999999115083351
214.39869247437869e-078.79738494875737e-070.999999560130753
221.81200650503215e-073.62401301006429e-070.99999981879935
239.08909399845154e-081.81781879969031e-070.99999990910906
242.44299505505447e-084.88599011010894e-080.99999997557005
256.4115580986214e-081.28231161972428e-070.999999935884419
262.17400454963829e-084.34800909927659e-080.999999978259954
271.85082391454231e-083.70164782908463e-080.99999998149176
281.36310441694477e-082.72620883388954e-080.999999986368956
294.50968510221349e-099.01937020442698e-090.999999995490315
302.11760808925906e-094.23521617851812e-090.999999997882392
312.07153318547725e-084.14306637095451e-080.999999979284668
326.64798014792329e-081.32959602958466e-070.999999933520199
335.30709320095791e-081.06141864019158e-070.999999946929068
345.03480712333801e-081.00696142466760e-070.999999949651929
351.66105600065558e-083.32211200131115e-080.99999998338944
361.70396883437120e-083.40793766874241e-080.999999982960312
377.35029213607018e-091.47005842721404e-080.999999992649708
383.8273871906135e-097.654774381227e-090.999999996172613
392.01405021513283e-094.02810043026565e-090.99999999798595
401.15834072813930e-092.31668145627860e-090.99999999884166
414.24928529013829e-108.49857058027657e-100.999999999575071
422.07088588729679e-104.14177177459357e-100.999999999792911
437.79062790696816e-111.55812558139363e-100.999999999922094
443.26031795986511e-116.52063591973023e-110.999999999967397
451.71691061423440e-113.43382122846879e-110.99999999998283
461.68999223098115e-113.37998446196230e-110.9999999999831
474.15669546858113e-118.31339093716226e-110.999999999958433
484.98779561857665e-119.9755912371533e-110.999999999950122
496.39630624769542e-111.27926124953908e-100.999999999936037
506.06801414310233e-111.21360282862047e-100.99999999993932
515.8933839780321e-111.17867679560642e-100.999999999941066
521.18063050389684e-102.36126100779367e-100.999999999881937
531.83401136194289e-103.66802272388578e-100.9999999998166
542.74695598270928e-095.49391196541856e-090.999999997253044
550.0004238417783068190.0008476835566136380.999576158221693
560.0006137867580578480.001227573516115700.999386213241942
570.0004149208287568680.0008298416575137360.999585079171243
580.0004927750056791360.0009855500113582730.99950722499432
590.0004599508996119130.0009199017992238260.999540049100388
600.0008271303378213570.001654260675642710.999172869662179
610.0009746016670226370.001949203334045270.999025398332977
620.0007774481530606120.001554896306121220.99922255184694
630.0005280315853522990.001056063170704600.999471968414648
640.0006768606459437130.001353721291887430.999323139354056
650.002520747618258180.005041495236516370.997479252381742
660.003810344912754920.007620689825509840.996189655087245
670.004192597491962830.008385194983925660.995807402508037
680.003557716844413290.007115433688826570.996442283155587
690.00236090204198660.00472180408397320.997639097958013
700.001509374381650220.003018748763300440.99849062561835
710.001606227450814850.00321245490162970.998393772549185
720.001726785679717580.003453571359435160.998273214320282
730.001326722752595480.002653445505190970.998673277247405
740.001671670508463440.003343341016926870.998328329491537
750.001458139850090620.002916279700181250.99854186014991
760.001151001582917140.002302003165834290.998848998417083
770.0008903026159259650.001780605231851930.999109697384074
780.001905853253310640.003811706506621270.99809414674669
790.002693653116003020.005387306232006040.997306346883997
800.002584132173835860.005168264347671710.997415867826164
810.00317104292458310.00634208584916620.996828957075417
820.007224023351718080.01444804670343620.992775976648282
830.009369474025621460.01873894805124290.990630525974379
840.0166409070182150.033281814036430.983359092981785
850.01400722032181280.02801444064362550.985992779678187
860.01163019097299570.02326038194599130.988369809027004
870.02634825563244480.05269651126488950.973651744367555
880.02872450998217640.05744901996435290.971275490017824
890.02290238107559190.04580476215118380.977097618924408
900.02078258734938030.04156517469876060.97921741265062
910.04009189165454460.08018378330908920.959908108345455
920.06356261082082640.1271252216416530.936437389179174
930.534261378448380.931477243103240.46573862155162
940.6677334230580840.6645331538838310.332266576941916
950.837094200383770.325811599232460.16290579961623
960.9804808387880740.03903832242385270.0195191612119264
970.9842485653424550.03150286931509000.0157514346575450
980.9793983477908220.04120330441835650.0206016522091783
990.9829753428573320.03404931428533560.0170246571426678
1000.9982461220909140.003507755818171850.00175387790908593
1010.999408561479720.001182877040561450.000591438520280725
1020.9982686822822250.00346263543555090.00173131771777545
1030.9951716115341750.00965677693164970.00482838846582485
1040.987937608063210.02412478387358080.0120623919367904
1050.9719262558762840.05614748824743230.0280737441237162
1060.923821144723050.1523577105539000.0761788552769498


Meta Analysis of Goldfeld-Quandt test for Heteroskedasticity
Description# significant tests% significant testsOK/NOK
1% type I error level740.778947368421053NOK
5% type I error level860.905263157894737NOK
10% type I error level900.947368421052632NOK
 
Charts produced by software:
http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/10eoet1292943782.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/10eoet1292943782.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/1iwh21292943782.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/1iwh21292943782.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/2iwh21292943782.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/2iwh21292943782.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/3iwh21292943782.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/3iwh21292943782.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/4sng51292943782.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/4sng51292943782.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/5sng51292943782.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/5sng51292943782.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/6sng51292943782.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/6sng51292943782.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/7lef81292943782.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/7lef81292943782.ps (open in new window)


http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/8eoet1292943782.png (open in new window)
http://www.freestatistics.org/blog/date/2010/Dec/21/t1292943801aduq0viqpc034dz/8eoet1292943782.ps (open in new window)


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