Free Statistics

of Irreproducible Research!

Author's title

Author*The author of this computation has been verified*
R Software Modulerwasp_Two Factor ANOVA.wasp
Title produced by softwareTwo-Way ANOVA
Date of computationSun, 04 Nov 2012 08:43:01 -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/2012/Nov/04/t1352036655cf95wj4q4c2ryd1.htm/, Retrieved Thu, 02 May 2024 19:14:36 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=185817, Retrieved Thu, 02 May 2024 19:14:36 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact117
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
-       [Two-Way ANOVA] [] [2012-11-04 13:43:01] [cd784a0623f47f402dddaa62da6ddd9f] [Current]
Feedback Forum

Post a new message
Dataseries X:
13	41	38
16	39	32
19	30	35
15	31	33
14	34	37
13	35	29
19	39	31
15	34	36
14	36	35
15	37	38
16	38	31
16	36	34
16	38	35
16	39	38
17	33	37
15	32	33
15	36	32
20	38	38
18	39	38
16	32	32
16	32	33
16	31	31
19	39	38
16	37	39
17	39	32
17	41	32
16	36	35
15	33	37
16	33	33
14	34	33
15	31	28
12	27	32
14	37	31
16	34	37
14	34	30
7	32	33
10	29	31
14	36	33
16	29	31
16	35	33
16	37	32
14	34	33
20	38	32
14	35	33
14	38	28
11	37	35
14	38	39
15	33	34
16	36	38
14	38	32
16	32	38
14	32	30
12	32	33
16	34	38
9	32	32
14	37	32
16	39	34
16	29	34
15	37	36
16	35	34
12	30	28
16	38	34
16	34	35
14	31	35
16	34	31
17	35	37
18	36	35
18	30	27
12	39	40
16	35	37
10	38	36
14	31	38
18	34	39
18	38	41
16	34	27
17	39	30
16	37	37
16	34	31
13	28	31
16	37	27
16	33	36
20	37	38
16	35	37
15	37	33
15	32	34
16	33	31
14	38	39
16	33	34
16	29	32
15	33	33
12	31	36
17	36	32
16	35	41
15	32	28
13	29	30
16	39	36
16	37	35
16	35	31
16	37	34
14	32	36
16	38	36
16	37	35
20	36	37
15	32	28
16	33	39
13	40	32
17	38	35
16	41	39
16	36	35
12	43	42
16	30	34
16	31	33
17	32	41
13	32	33
12	37	34
18	37	32
14	33	40
14	34	40
13	33	35
16	38	36
13	33	37
16	31	27
13	38	39
16	37	38
15	33	31
16	31	33
15	39	32
17	44	39
15	33	36
12	35	33
16	32	33
10	28	32
16	40	37
12	27	30
14	37	38
15	32	29
13	28	22
15	34	35
11	30	35
12	35	34
8	31	35
16	32	34
15	30	34
17	30	35
16	31	23
10	40	31
18	32	27
13	36	36
16	32	31
13	35	32
10	38	39
15	42	37
16	34	38
16	35	39
14	35	34
10	33	31
17	36	32
13	32	37
15	33	36
16	34	32
12	32	35
13	34	36




Summary of computational transaction
Raw Inputview raw input (R code)
Raw Outputview raw output of R engine
Computing time3 seconds
R Server'George Udny Yule' @ yule.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 & 'George Udny Yule' @ yule.wessa.net \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=185817&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]'George Udny Yule' @ yule.wessa.net[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=185817&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=185817&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'George Udny Yule' @ yule.wessa.net







ANOVA Model
Response ~ Treatment_A * Treatment_B - 1
means15132015.9172115.75222214.75232016.75202020191221-5-4-2.75-1.75-3-10-3-5-4-0.25-4-4-7-4-81.25NANANANANANANANANANANANANANANANANANANANA6.083-16.25NA-2NANANANANANANANANANANANA-1.167-3.252NANANANANANANANANANANANANANANANA1NANANANANANANANANANANANANA-4NANA1.25NA-5NANANANA0NANANANANA103NA510.251.667411.25NA49.259NANANANANANA-1NANA-0.25NA-31.25-3.667-13.25-1-4NANANANANANANA-0.3332.417-1.5-34.25-4NANANANANANANANANANA3.583NA3.75-2.5NA3.25-3-23.25NANANANANANANANANA-9.75-3.5-8.75-6.25NA-6.75-5.417NANANANANANANANANANA-52.25-2.667-4NA-6-11.25NANANANANANANANANANA1.25-3-35.5831NANANANANANANANANANANANA7.25NA1NANA3.2510.254.667NANANANANANANANANANA-2NA5.25NANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANA

\begin{tabular}{lllllllll}
\hline
ANOVA Model \tabularnewline
Response ~ Treatment_A * Treatment_B - 1 \tabularnewline
means & 15 & 13 & 20 & 15.917 & 21 & 15.75 & 22 & 22 & 14.75 & 23 & 20 & 16.75 & 20 & 20 & 20 & 19 & 12 & 21 & -5 & -4 & -2.75 & -1.75 & -3 & -10 & -3 & -5 & -4 & -0.25 & -4 & -4 & -7 & -4 & -8 & 1.25 & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & 6.083 & -1 & 6.25 & NA & -2 & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & -1.167 & -3.25 & 2 & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & 1 & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & -4 & NA & NA & 1.25 & NA & -5 & NA & NA & NA & NA & 0 & NA & NA & NA & NA & NA & 10 & 3 & NA & 5 & 10.25 & 1.667 & 4 & 11.25 & NA & 4 & 9.25 & 9 & NA & NA & NA & NA & NA & NA & -1 & NA & NA & -0.25 & NA & -3 & 1.25 & -3.667 & -1 & 3.25 & -1 & -4 & NA & NA & NA & NA & NA & NA & NA & -0.333 & 2.417 & -1.5 & -3 & 4.25 & -4 & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & 3.583 & NA & 3.75 & -2.5 & NA & 3.25 & -3 & -2 & 3.25 & NA & NA & NA & NA & NA & NA & NA & NA & NA & -9.75 & -3.5 & -8.75 & -6.25 & NA & -6.75 & -5.417 & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & -5 & 2.25 & -2.667 & -4 & NA & -6 & -1 & 1.25 & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & 1.25 & -3 & -3 & 5.583 & 1 & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & 7.25 & NA & 1 & NA & NA & 3.25 & 10.25 & 4.667 & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & -2 & NA & 5.25 & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA & NA \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=185817&T=1

[TABLE]
[ROW]ANOVA Model[/C][/ROW]
[ROW]Response ~ Treatment_A * Treatment_B - 1[/C][/ROW]
[ROW][C]means[/C][C]15[/C][C]13[/C][C]20[/C][C]15.917[/C][C]21[/C][C]15.75[/C][C]22[/C][C]22[/C][C]14.75[/C][C]23[/C][C]20[/C][C]16.75[/C][C]20[/C][C]20[/C][C]20[/C][C]19[/C][C]12[/C][C]21[/C][C]-5[/C][C]-4[/C][C]-2.75[/C][C]-1.75[/C][C]-3[/C][C]-10[/C][C]-3[/C][C]-5[/C][C]-4[/C][C]-0.25[/C][C]-4[/C][C]-4[/C][C]-7[/C][C]-4[/C][C]-8[/C][C]1.25[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]6.083[/C][C]-1[/C][C]6.25[/C][C]NA[/C][C]-2[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]-1.167[/C][C]-3.25[/C][C]2[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]1[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]-4[/C][C]NA[/C][C]NA[/C][C]1.25[/C][C]NA[/C][C]-5[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]0[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]10[/C][C]3[/C][C]NA[/C][C]5[/C][C]10.25[/C][C]1.667[/C][C]4[/C][C]11.25[/C][C]NA[/C][C]4[/C][C]9.25[/C][C]9[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]-1[/C][C]NA[/C][C]NA[/C][C]-0.25[/C][C]NA[/C][C]-3[/C][C]1.25[/C][C]-3.667[/C][C]-1[/C][C]3.25[/C][C]-1[/C][C]-4[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]-0.333[/C][C]2.417[/C][C]-1.5[/C][C]-3[/C][C]4.25[/C][C]-4[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]3.583[/C][C]NA[/C][C]3.75[/C][C]-2.5[/C][C]NA[/C][C]3.25[/C][C]-3[/C][C]-2[/C][C]3.25[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]-9.75[/C][C]-3.5[/C][C]-8.75[/C][C]-6.25[/C][C]NA[/C][C]-6.75[/C][C]-5.417[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]-5[/C][C]2.25[/C][C]-2.667[/C][C]-4[/C][C]NA[/C][C]-6[/C][C]-1[/C][C]1.25[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]1.25[/C][C]-3[/C][C]-3[/C][C]5.583[/C][C]1[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]7.25[/C][C]NA[/C][C]1[/C][C]NA[/C][C]NA[/C][C]3.25[/C][C]10.25[/C][C]4.667[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]-2[/C][C]NA[/C][C]5.25[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][C]NA[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=185817&T=1

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

As an alternative you can also use a QR Code:  

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

ANOVA Model
Response ~ Treatment_A * Treatment_B - 1
means15132015.9172115.75222214.75232016.75202020191221-5-4-2.75-1.75-3-10-3-5-4-0.25-4-4-7-4-81.25NANANANANANANANANANANANANANANANANANANANA6.083-16.25NA-2NANANANANANANANANANANANA-1.167-3.252NANANANANANANANANANANANANANANANA1NANANANANANANANANANANANANA-4NANA1.25NA-5NANANANA0NANANANANA103NA510.251.667411.25NA49.259NANANANANANA-1NANA-0.25NA-31.25-3.667-13.25-1-4NANANANANANANA-0.3332.417-1.5-34.25-4NANANANANANANANANANA3.583NA3.75-2.5NA3.25-3-23.25NANANANANANANANANA-9.75-3.5-8.75-6.25NA-6.75-5.417NANANANANANANANANANA-52.25-2.667-4NA-6-11.25NANANANANANANANANANA1.25-3-35.5831NANANANANANANANANANANANA7.25NA1NANA3.2510.254.667NANANANANANANANANANA-2NA5.25NANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANANA







ANOVA Statistics
DfSum SqMean SqF valuePr(>F)
18
Treatment_A1836340.4072018.912359.6850
Treatment_B1899.766.2351.1110.367
Treatment_A:Treatment_B18258.6663.7490.6680.947
Residuals59331.1675.613

\begin{tabular}{lllllllll}
\hline
ANOVA Statistics \tabularnewline
  & Df & Sum Sq & Mean Sq & F value & Pr(>F) \tabularnewline
 & 18 &  &  &  &  \tabularnewline
Treatment_A & 18 & 36340.407 & 2018.912 & 359.685 & 0 \tabularnewline
Treatment_B & 18 & 99.76 & 6.235 & 1.111 & 0.367 \tabularnewline
Treatment_A:Treatment_B & 18 & 258.666 & 3.749 & 0.668 & 0.947 \tabularnewline
Residuals & 59 & 331.167 & 5.613 &   &   \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=185817&T=2

[TABLE]
[ROW][C]ANOVA Statistics[/C][/ROW]
[ROW][C] [/C][C]Df[/C][C]Sum Sq[/C][C]Mean Sq[/C][C]F value[/C][C]Pr(>F)[/C][/ROW]
[ROW][C][/C][C]18[/C][C][/C][C][/C][C][/C][C][/C][/ROW]
[ROW][C]Treatment_A[/C][C]18[/C][C]36340.407[/C][C]2018.912[/C][C]359.685[/C][C]0[/C][/ROW]
[ROW][C]Treatment_B[/C][C]18[/C][C]99.76[/C][C]6.235[/C][C]1.111[/C][C]0.367[/C][/ROW]
[ROW][C]Treatment_A:Treatment_B[/C][C]18[/C][C]258.666[/C][C]3.749[/C][C]0.668[/C][C]0.947[/C][/ROW]
[ROW][C]Residuals[/C][C]59[/C][C]331.167[/C][C]5.613[/C][C] [/C][C] [/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=185817&T=2

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

As an alternative you can also use a QR Code:  

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

ANOVA Statistics
DfSum SqMean SqF valuePr(>F)
18
Treatment_A1836340.4072018.912359.6850
Treatment_B1899.766.2351.1110.367
Treatment_A:Treatment_B18258.6663.7490.6680.947
Residuals59331.1675.613







Must Include Intercept to use Tukey Test

\begin{tabular}{lllllllll}
\hline
Must Include Intercept to use Tukey Test  \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=185817&T=3

[TABLE]
[ROW][C]Must Include Intercept to use Tukey Test [/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=185817&T=3

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

As an alternative you can also use a QR Code:  

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

Must Include Intercept to use Tukey Test







Levenes Test for Homogeneity of Variance
DfF valuePr(>F)
Group1020.6050.987
59

\begin{tabular}{lllllllll}
\hline
Levenes Test for Homogeneity of Variance \tabularnewline
  & Df & F value & Pr(>F) \tabularnewline
Group & 102 & 0.605 & 0.987 \tabularnewline
  & 59 &   &   \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=185817&T=4

[TABLE]
[ROW][C]Levenes Test for Homogeneity of Variance[/C][/ROW]
[ROW][C] [/C][C]Df[/C][C]F value[/C][C]Pr(>F)[/C][/ROW]
[ROW][C]Group[/C][C]102[/C][C]0.605[/C][C]0.987[/C][/ROW]
[ROW][C] [/C][C]59[/C][C] [/C][C] [/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=185817&T=4

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

As an alternative you can also use a QR Code:  

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

Levenes Test for Homogeneity of Variance
DfF valuePr(>F)
Group1020.6050.987
59



Parameters (Session):
par1 = 1 ; par2 = 2 ; par3 = 3 ; par4 = FALSE ;
Parameters (R input):
par1 = 1 ; par2 = 2 ; par3 = 3 ; par4 = FALSE ;
R code (references can be found in the software module):
cat1 <- as.numeric(par1) #
cat2<- as.numeric(par2) #
cat3 <- as.numeric(par3)
intercept<-as.logical(par4)
x <- t(x)
x1<-as.numeric(x[,cat1])
f1<-as.character(x[,cat2])
f2 <- as.character(x[,cat3])
xdf<-data.frame(x1,f1, f2)
(V1<-dimnames(y)[[1]][cat1])
(V2<-dimnames(y)[[1]][cat2])
(V3 <-dimnames(y)[[1]][cat3])
names(xdf)<-c('Response', 'Treatment_A', 'Treatment_B')
if(intercept == FALSE) (lmxdf<-lm(Response ~ Treatment_A * Treatment_B- 1, data = xdf) ) else (lmxdf<-lm(Response ~ Treatment_A * Treatment_B, data = xdf) )
(aov.xdf<-aov(lmxdf) )
(anova.xdf<-anova(lmxdf) )
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'ANOVA Model', length(lmxdf$coefficients)+1,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, lmxdf$call['formula'],length(lmxdf$coefficients)+1,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, 'means',,TRUE)
for(i in 1:length(lmxdf$coefficients)){
a<-table.element(a, round(lmxdf$coefficients[i], digits=3),,FALSE)
}
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable.tab')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'ANOVA Statistics', 5+1,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, ' ',,TRUE)
a<-table.element(a, 'Df',,FALSE)
a<-table.element(a, 'Sum Sq',,FALSE)
a<-table.element(a, 'Mean Sq',,FALSE)
a<-table.element(a, 'F value',,FALSE)
a<-table.element(a, 'Pr(>F)',,FALSE)
a<-table.row.end(a)
for(i in 1 : length(rownames(anova.xdf))-1){
a<-table.row.start(a)
a<-table.element(a,rownames(anova.xdf)[i] ,,TRUE)
a<-table.element(a, anova.xdf$Df[1],,FALSE)
a<-table.element(a, round(anova.xdf$'Sum Sq'[i], digits=3),,FALSE)
a<-table.element(a, round(anova.xdf$'Mean Sq'[i], digits=3),,FALSE)
a<-table.element(a, round(anova.xdf$'F value'[i], digits=3),,FALSE)
a<-table.element(a, round(anova.xdf$'Pr(>F)'[i], digits=3),,FALSE)
a<-table.row.end(a)
}
a<-table.row.start(a)
a<-table.element(a, 'Residuals',,TRUE)
a<-table.element(a, anova.xdf$'Df'[i+1],,FALSE)
a<-table.element(a, round(anova.xdf$'Sum Sq'[i+1], digits=3),,FALSE)
a<-table.element(a, round(anova.xdf$'Mean Sq'[i+1], digits=3),,FALSE)
a<-table.element(a, ' ',,FALSE)
a<-table.element(a, ' ',,FALSE)
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable1.tab')
bitmap(file='anovaplot.png')
boxplot(Response ~ Treatment_A + Treatment_B, data=xdf, xlab=V2, ylab=V1, main='Boxplots of ANOVA Groups')
dev.off()
bitmap(file='designplot.png')
xdf2 <- xdf # to preserve xdf make copy for function
names(xdf2) <- c(V1, V2, V3)
plot.design(xdf2, main='Design Plot of Group Means')
dev.off()
bitmap(file='interactionplot.png')
interaction.plot(xdf$Treatment_A, xdf$Treatment_B, xdf$Response, xlab=V2, ylab=V1, trace.label=V3, main='Possible Interactions Between Anova Groups')
dev.off()
if(intercept==TRUE){
thsd<-TukeyHSD(aov.xdf)
names(thsd) <- c(V2, V3, paste(V2, ':', V3, sep=''))
bitmap(file='TukeyHSDPlot.png')
layout(matrix(c(1,2,3,3), 2,2))
plot(thsd, las=1)
dev.off()
}
if(intercept==TRUE){
ntables<-length(names(thsd))
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Tukey Honest Significant Difference Comparisons', 5,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a, ' ', 1, TRUE)
for(i in 1:4){
a<-table.element(a,colnames(thsd[[1]])[i], 1, TRUE)
}
a<-table.row.end(a)
for(nt in 1:ntables){
for(i in 1:length(rownames(thsd[[nt]]))){
a<-table.row.start(a)
a<-table.element(a,rownames(thsd[[nt]])[i], 1, TRUE)
for(j in 1:4){
a<-table.element(a,round(thsd[[nt]][i,j], digits=3), 1, FALSE)
}
a<-table.row.end(a)
}
} # end nt
a<-table.end(a)
table.save(a,file='hsdtable.tab')
}#end if hsd tables
if(intercept==FALSE){
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'TukeyHSD Message', 1,TRUE)
a<-table.row.end(a)
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Must Include Intercept to use Tukey Test ', 1, FALSE)
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable2.tab')
}
library(car)
lt.lmxdf<-levene.test(lmxdf)
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,'Levenes Test for Homogeneity of Variance', 4,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,' ', 1, TRUE)
for (i in 1:3){
a<-table.element(a,names(lt.lmxdf)[i], 1, FALSE)
}
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Group', 1, TRUE)
for (i in 1:3){
a<-table.element(a,round(lt.lmxdf[[i]][1], digits=3), 1, FALSE)
}
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,' ', 1, TRUE)
a<-table.element(a,lt.lmxdf[[1]][2], 1, FALSE)
a<-table.element(a,' ', 1, FALSE)
a<-table.element(a,' ', 1, FALSE)
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable3.tab')