Free Statistics

of Irreproducible Research!

Author's title

Author*Unverified author*
R Software Modulerwasp_linear_regression.wasp
Title produced by softwareLinear Regression Graphical Model Validation
Date of computationTue, 15 Nov 2011 17:50:40 -0500
Cite this page as followsStatistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?v=date/2011/Nov/15/t1321397477i3fblkj0ofzmmzg.htm/, Retrieved Fri, 29 Mar 2024 10:34:40 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=143647, Retrieved Fri, 29 Mar 2024 10:34:40 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact56
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
-     [Linear Regression Graphical Model Validation] [Colombia Coffee -...] [2008-02-26 10:22:06] [74be16979710d4c4e7c6647856088456]
- RM D  [Linear Regression Graphical Model Validation] [Tutorial] [2011-11-15 22:38:28] [74be16979710d4c4e7c6647856088456]
-    D      [Linear Regression Graphical Model Validation] [ws6 tutorial] [2011-11-15 22:50:40] [d41d8cd98f00b204e9800998ecf8427e] [Current]
Feedback Forum

Post a new message
Dataseries X:
55,57
56,5
53,83
52,29
50,97
51,18
51,5
53,8
50,7
49,05
48,44
53,77
54,67
53,96
54,03
50,52
48,83
53,93
62,2
58,23
60,93
63,06
61,77
64,48
69,38
71
77,89
71,43
69,15
69,88
69,64
67,18
61,18
50,14
42,2
44,8
49,04
45,56
42,63
49,2
57,43
54,11
58,65
58,6
60,15
65,36
68,83
73,61
72
74,46
81,22
81,41
80,62
81,43
80,84
82,4
91,32
103,89
132,32
142,13
142,2
143,78
145,2
141,22
140,6
143,25
147,25
147,97
144,06
141,44
141,44
145,44
148,94
152,94
156,94
161,94
161,83
166,83
169,39
164,75
168,44
151,23
172,22
176,22
171,86
167,86
174,51
175,29
180,58
187,58
189,97
186,05
190,02
197,02
204,02
197,02
197,02
187,94
186,56
181,28
191,34
196,52
185,54
195,87
204,45
208,2
215,15
214,5
207,04
205,99
200,98
204,94
197,94
190,94
185,12
192,12
199,12
198,96
205,96
201,87
208,82
204,49
197,99
194,88
193,67
200,23
201,27
195,55
195,55
201,06
208,06
208,06
202,97
204,58
199,73
197,35
196,04
195,52
196,45
189,82
183,17
186,67
186,67
188
181,84
174,89
172,82
178,78
192,55
175,91
179,21
173,19
165,36
153,8
145,4
151,4
150,3
144,3
145,15
151,15
155,04
159,86
155,65
155,61
153,89
153,88
156,03
151,03
151,03
153,5
158,67
156,33
160,97
164,24
161,63
155,63
148,63
145,05
151,05
150,03
150,95
155,55
151,96
145,96
145,18
148,73
154,73
161,22
164,55
165,22
162
160,91
162,14
159,79
155,73
159,79
161,5
159
155,4
136,2
116,58
111,58
106,59
110,35
106,35
101,46
97,95
101,95
101,29
99,33
99,14
97,09
101,09
103,85
102,81
102,08
115,78
105,59
107,17
104,42
105,01
101,48
99,01
97,26
99,16
97,79
100,72
105,03
104,62
108,43
107,55
106,76
106,61
105,14
104,62
102,59
103,92
104,77
104,91
105,88
103,85
106,08
106,08
106,3
106,24
110,02
112,45
110,3
110,72
111,56
113,39
110,62
109,08
104,08
103,81
101,27
97,64
99,99
98,43
99,39
98,33
100,97
99,31
105,28
97,75
100,92
102,75
102,25
101,48
103,34
103,47
100,51
101,56
101,94
100,36
100,18
99,72
96,86
97,1
97,94
99,68
100,32
104,32
104,37
102,29
100,91
Dataseries Y:
65,03
61,94
62,68
69,8
70,81
70,9
74,52
73,18
64,33
59,44
59,36
62,16
54,37
59,11
60,55
64,04
63,75
67,29
73,73
72,39
78,86
85,16
94,71
91,29
92,56
94,84
105,12
111,67
125,45
133,69
134,08
117
103,88
77,6
57,55
42,78
41,43
39,15
47,48
49,7
58,79
69,59
64,27
71
69,27
75,47
77,97
74,61
79,55
77,3
81,1
84,65
74,22
75,4
76,03
76,67
75,01
81,96
84,25
89,25
91,55
88,92
90,3
88,8
88,03
89,13
91,11
91,94
91,45
91,54
91,02
91,38
91,06
88,86
89,11
88,15
86,19
87,35
86
89,34
92
89,68
90,77
91,08
90,67
89,03
87,69
86,94
86,75
86,9
85,58
85,4
84,32
85,13
86,03
86,2
91,42
93,57
98,9
99,48
97,88
97,94
90,08
99,63
102,2
101,28
104,42
105,15
105,02
104,76
103,33
101,16
101,19
97,18
97,98
101,42
101,07
102,33
102,33
104
105,6
105,4
104,77
104,79
104,31
106,46
102,86
107,94
108,1
108,35
108,47
108,83
112,79
110,46
106,25
106,53
107,95
109,66
107,16
108,15
111,16
112,19
112,35
112,2
111,9
112,76
112,53
113,5
109,96
113,89
111,05
109,16
101
97,18
102,19
103,88
99,35
99,77
99,65
97,69
96,91
100,93
99,06
99,49
97,83
99,59
101,14
100,53
100,59
100,59
102,8
101,56
100,29
100,51
100,22
100,22
99,01
99,09
100,74
99,29
96,9
97,3
99,37
94,81
93,01
93,26
93,26
94,16
95,41
91,16
91,16
90,61
92,89
94,77
96,25
94,94
94,94
94,94
96,89
96,65
96,2
96,2
95,15
97,43
98,05
97,24
97,24
95,93
97,5
98,4
99,87
99,28
99,2
99,59
97,4
95,2
97,06
95,7
94,89
93,79
86,68
86,88
86,88
79,3
80,66
83,75
85,38
87,27
86,65
87,74
87,58
82,26
82,26
85,44
85,9
85,08
85,37
85,37
88,9
88,84
86,63
89,08
86,45
86,45
86,02
89,53
89,19
87,24
87,91
90,21
89
89,28
87,96
85,28
86,89
86,39
85,92
79,85
80,58
84,45
81,67
82,82
79,2
85,97
77,61
75,67
79,16
79,68
82,98
85,6
86,41
85,57
84,77
86,8
86,48
88,34
88,21
86,11
87,4
87,4
91,59
93,17
90,2
93,96
93,2
86,21




Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time3 seconds
R Server'Gertrude Mary Cox' @ cox.wessa.net

\begin{tabular}{lllllllll}
\hline
Summary of computational transaction \tabularnewline
Raw Input & view raw input (R code)  \tabularnewline
Raw Output & view raw output of R engine  \tabularnewline
Computing time & 3 seconds \tabularnewline
R Server & 'Gertrude Mary Cox' @ cox.wessa.net \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=143647&T=0

[TABLE]
[ROW][C]Summary of computational transaction[/C][/ROW]
[ROW][C]Raw Input[/C][C]view raw input (R code) [/C][/ROW]
[ROW][C]Raw Output[/C][C]view raw output of R engine [/C][/ROW]
[ROW][C]Computing time[/C][C]3 seconds[/C][/ROW]
[ROW][C]R Server[/C][C]'Gertrude Mary Cox' @ cox.wessa.net[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=143647&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=143647&T=0

As an alternative you can also use a QR Code:  

The GUIDs for individual cells are displayed in the table below:

Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time3 seconds
R Server'Gertrude Mary Cox' @ cox.wessa.net







Simple Linear Regression
StatisticsEstimateS.D.T-STAT (H0: coeff=0)P-value (two-sided)
constant term65.3730865233031.7954030769551236.41137043954010
slope0.1956952035508770.01299652173575615.05750596426740

\begin{tabular}{lllllllll}
\hline
Simple Linear Regression \tabularnewline
Statistics & Estimate & S.D. & T-STAT (H0: coeff=0) & P-value (two-sided) \tabularnewline
constant term & 65.373086523303 & 1.79540307695512 & 36.4113704395401 & 0 \tabularnewline
slope & 0.195695203550877 & 0.012996521735756 & 15.0575059642674 & 0 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=143647&T=1

[TABLE]
[ROW][C]Simple Linear Regression[/C][/ROW]
[ROW][C]Statistics[/C][C]Estimate[/C][C]S.D.[/C][C]T-STAT (H0: coeff=0)[/C][C]P-value (two-sided)[/C][/ROW]
[ROW][C]constant term[/C][C]65.373086523303[/C][C]1.79540307695512[/C][C]36.4113704395401[/C][C]0[/C][/ROW]
[ROW][C]slope[/C][C]0.195695203550877[/C][C]0.012996521735756[/C][C]15.0575059642674[/C][C]0[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=143647&T=1

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=143647&T=1

As an alternative you can also use a QR Code:  

The GUIDs for individual cells are displayed in the table below:

Simple Linear Regression
StatisticsEstimateS.D.T-STAT (H0: coeff=0)P-value (two-sided)
constant term65.3730865233031.7954030769551236.41137043954010
slope0.1956952035508770.01299652173575615.05750596426740



Parameters (Session):
par1 = 0 ;
Parameters (R input):
par1 = 0 ;
R code (references can be found in the software module):
par1 <- as.numeric(par1)
library(lattice)
z <- as.data.frame(cbind(x,y))
m <- lm(y~x)
summary(m)
bitmap(file='test1.png')
plot(z,main='Scatterplot, lowess, and regression line')
lines(lowess(z),col='red')
abline(m)
grid()
dev.off()
bitmap(file='test2.png')
m2 <- lm(m$fitted.values ~ x)
summary(m2)
z2 <- as.data.frame(cbind(x,m$fitted.values))
names(z2) <- list('x','Fitted')
plot(z2,main='Scatterplot, lowess, and regression line')
lines(lowess(z2),col='red')
abline(m2)
grid()
dev.off()
bitmap(file='test3.png')
m3 <- lm(m$residuals ~ x)
summary(m3)
z3 <- as.data.frame(cbind(x,m$residuals))
names(z3) <- list('x','Residuals')
plot(z3,main='Scatterplot, lowess, and regression line')
lines(lowess(z3),col='red')
abline(m3)
grid()
dev.off()
bitmap(file='test4.png')
m4 <- lm(m$fitted.values ~ m$residuals)
summary(m4)
z4 <- as.data.frame(cbind(m$residuals,m$fitted.values))
names(z4) <- list('Residuals','Fitted')
plot(z4,main='Scatterplot, lowess, and regression line')
lines(lowess(z4),col='red')
abline(m4)
grid()
dev.off()
bitmap(file='test5.png')
myr <- as.ts(m$residuals)
z5 <- as.data.frame(cbind(lag(myr,1),myr))
names(z5) <- list('Lagged Residuals','Residuals')
plot(z5,main='Lag plot')
m5 <- lm(z5)
summary(m5)
abline(m5)
grid()
dev.off()
bitmap(file='test6.png')
hist(m$residuals,main='Residual Histogram',xlab='Residuals')
dev.off()
bitmap(file='test7.png')
if (par1 > 0)
{
densityplot(~m$residuals,col='black',main=paste('Density Plot bw = ',par1),bw=par1)
} else {
densityplot(~m$residuals,col='black',main='Density Plot')
}
dev.off()
bitmap(file='test8.png')
acf(m$residuals,main='Residual Autocorrelation Function')
dev.off()
bitmap(file='test9.png')
qqnorm(x)
qqline(x)
grid()
dev.off()
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Simple Linear Regression',5,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Statistics',1,TRUE)
a<-table.element(a,'Estimate',1,TRUE)
a<-table.element(a,'S.D.',1,TRUE)
a<-table.element(a,'T-STAT (H0: coeff=0)',1,TRUE)
a<-table.element(a,'P-value (two-sided)',1,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'constant term',header=TRUE)
a<-table.element(a,m$coefficients[[1]])
sd <- sqrt(vcov(m)[1,1])
a<-table.element(a,sd)
tstat <- m$coefficients[[1]]/sd
a<-table.element(a,tstat)
pval <- 2*(1-pt(abs(tstat),length(x)-2))
a<-table.element(a,pval)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'slope',header=TRUE)
a<-table.element(a,m$coefficients[[2]])
sd <- sqrt(vcov(m)[2,2])
a<-table.element(a,sd)
tstat <- m$coefficients[[2]]/sd
a<-table.element(a,tstat)
pval <- 2*(1-pt(abs(tstat),length(x)-2))
a<-table.element(a,pval)
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable.tab')