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 computationThu, 20 Dec 2018 22:36:16 +0100
Cite this page as followsStatistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?v=date/2018/Dec/21/t1545395050irpkdiasq8bpmlj.htm/, Retrieved Sat, 04 May 2024 05:40:08 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=316167, Retrieved Sat, 04 May 2024 05:40:08 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact55
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
-       [Two-Way ANOVA] [] [2018-12-20 21:36:16] [75d482958c523455764bdc71248b843b] [Current]
Feedback Forum

Post a new message
Dataseries X:
5	'S'	1
10	'S'	1
8	'S'	1
9	'S'	1
8	'S'	1
7	'S'	3
10	'S'	1
10	'S'	1
9	'S'	1
4	'S'	1
4	'S'	1
8	'S'	3
9	'S'	1
10	'S'	1
8	'S'	1
5	'S'	3
10	'S'	1
8	'S'	1
7	'S'	0
8	'S'	1
8	'S'	3
9	'S'	1
8	'S'	1
6	'S'	1
8	'S'	1
8	'S'	1
5	'B'	3
9	'S'	1
8	'S'	3
8	'S'	3
8	'S'	1
6	'S'	1
6	'S'	1
9	'S'	1
8	'S'	1
9	'S'	1
10	'S'	1
8	'B'	0
8	'S'	1
7	'S'	1
7	'S'	1
10	'S'	1
8	'S'	1
7	'S'	1
10	'S'	3
7	'S'	1
7	'S'	1
9	'S'	1
9	'S'	1
8	'S'	1
6	'S'	3
8	'S'	3
9	'S'	1
2	'B'	3
6	'S'	3
8	'S'	1
8	'B'	3
7	'B'	3
8	'S'	3
6	'S'	1
10	'S'	3
10	'S'	1
10	'S'	1
8	'S'	1
8	'S'	3
7	'S'	3
10	'S'	1
5	'B'	3
3	'B'	3
2	'B'	3
3	'B'	3
4	'B'	3
2	'B'	3
6	'B'	3
8	'S'	1
8	'S'	1
5	'B'	3
10	'S'	0
9	'S'	3
8	'S'	3
9	'S'	1
8	'S'	1
5	'S'	1
7	'S'	3
9	'S'	3
8	'S'	1
4	'S'	1
7	'S'	0
8	'S'	1
7	'S'	1
7	'S'	3
9	'S'	1
6	'S'	1
7	'S'	1
4	'S'	1
6	'S'	3
10	'S'	1
9	'S'	1
10	'S'	1
8	'S'	3
4	'B'	3
8	'S'	2
5	'S'	1
8	'B'	3
9	'B'	3
8	'S'	1
4	'S'	2
8	'S'	1
10	'S'	1
6	'S'	3
7	'S'	1
10	'S'	1
9	'S'	3
8	'S'	1
3	'B'	3
8	'S'	1
7	'S'	0
7	'S'	3
8	'S'	1
8	'S'	0
7	'S'	0
7	'B'	3
9	'S'	1
9	'B'	3
9	'S'	1
4	'B'	3
6	'S'	3
6	'S'	1
6	'B'	3
8	'S'	1
3	'B'	3
8	'B'	3
8	'B'	3
6	'B'	3
10	'S'	1
2	'B'	3
9	'B'	3
6	'B'	3
6	'B'	2
5	'B'	3
4	'B'	3
7	'S'	1
5	'B'	3
8	'B'	3
6	'B'	3
9	'B'	3
6	'S'	3
4	'B'	3
7	'B'	3
2	'B'	3
8	'S'	1
9	'S'	1
6	'S'	1
5	'B'	3
7	'B'	3
8	'S'	3
4	'S'	3
9	'B'	3
9	'S'	3
9	'B'	3
7	'B'	3
5	'S'	1
7	'B'	3
9	'S'	1
8	'S'	1
6	'B'	3
9	'B'	3
8	'S'	1
7	'S'	0
7	'S'	1
7	'B'	1
8	'S'	1
10	'S'	1
6	'B'	3
6	'B'	3




Summary of computational transaction
Raw Input view raw input (R code)
Raw Outputview raw output of R engine
Computing time10 seconds
R ServerBig Analytics Cloud Computing Center

\begin{tabular}{lllllllll}
\hline
Summary of computational transaction \tabularnewline
Raw Input view raw input (R code)  \tabularnewline
Raw Outputview raw output of R engine  \tabularnewline
Computing time10 seconds \tabularnewline
R ServerBig Analytics Cloud Computing Center \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=316167&T=0

[TABLE]
[ROW]
Summary of computational transaction[/C][/ROW] [ROW]Raw Input[/C] view raw input (R code) [/C][/ROW] [ROW]Raw Output[/C]view raw output of R engine [/C][/ROW] [ROW]Computing time[/C]10 seconds[/C][/ROW] [ROW]R Server[/C]Big Analytics Cloud Computing Center[/C][/ROW] [/TABLE] Source: https://freestatistics.org/blog/index.php?pk=316167&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=316167&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 Input view raw input (R code)
Raw Outputview raw output of R engine
Computing time10 seconds
R ServerBig Analytics Cloud Computing Center







ANOVA Model
Response ~ Treatment_A * Treatment_B
means8-0.429-1-2-2.2391.3940.4292.116

\begin{tabular}{lllllllll}
\hline
ANOVA Model \tabularnewline
Response ~ Treatment_A * Treatment_B \tabularnewline
means & 8 & -0.429 & -1 & -2 & -2.239 & 1.394 & 0.429 & 2.116 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=316167&T=1

[TABLE]
[ROW][C]ANOVA Model[/C][/ROW]
[ROW][C]Response ~ Treatment_A * Treatment_B[/C][/ROW]
[ROW][C]means[/C][C]8[/C][C]-0.429[/C][C]-1[/C][C]-2[/C][C]-2.239[/C][C]1.394[/C][C]0.429[/C][C]2.116[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=316167&T=1

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=316167&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
means8-0.429-1-2-2.2391.3940.4292.116







ANOVA Statistics
DfSum SqMean SqF valuePr(>F)
1
Treatment_A1135.105135.10543.3770
Treatment_B113.5144.5051.4460.231
Treatment_A:Treatment_B15.6611.8870.6060.612
Residuals167520.1543.115

\begin{tabular}{lllllllll}
\hline
ANOVA Statistics \tabularnewline
  & Df & Sum Sq & Mean Sq & F value & Pr(>F) \tabularnewline
 & 1 &  &  &  &  \tabularnewline
Treatment_A & 1 & 135.105 & 135.105 & 43.377 & 0 \tabularnewline
Treatment_B & 1 & 13.514 & 4.505 & 1.446 & 0.231 \tabularnewline
Treatment_A:Treatment_B & 1 & 5.661 & 1.887 & 0.606 & 0.612 \tabularnewline
Residuals & 167 & 520.154 & 3.115 &   &   \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=316167&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]1[/C][C][/C][C][/C][C][/C][C][/C][/ROW]
[ROW][C]Treatment_A[/C][C]1[/C][C]135.105[/C][C]135.105[/C][C]43.377[/C][C]0[/C][/ROW]
[ROW][C]Treatment_B[/C][C]1[/C][C]13.514[/C][C]4.505[/C][C]1.446[/C][C]0.231[/C][/ROW]
[ROW][C]Treatment_A:Treatment_B[/C][C]1[/C][C]5.661[/C][C]1.887[/C][C]0.606[/C][C]0.612[/C][/ROW]
[ROW][C]Residuals[/C][C]167[/C][C]520.154[/C][C]3.115[/C][C] [/C][C] [/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=316167&T=2

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=316167&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)
1
Treatment_A1135.105135.10543.3770
Treatment_B113.5144.5051.4460.231
Treatment_A:Treatment_B15.6611.8870.6060.612
Residuals167520.1543.115







Tukey Honest Significant Difference Comparisons
difflwruprp adj
S-B1.9571.372.5440
1-00.107-1.5831.7980.998
2-0-1.217-4.3181.8830.739
3-0-0.256-1.9591.4470.98
2-1-1.325-4.0131.3640.578
3-1-0.363-1.0810.3540.555
3-20.961-1.7353.6580.791
S:0-B:0-0.429-6.225.3631
B:1-B:0-1-8.6626.6621
S:1-B:0-0.034-5.4825.4141
B:2-B:0-2-9.6625.6620.993
S:2-B:0-2-8.6354.6350.983
B:3-B:0-2.239-7.7153.2370.914
S:3-B:0-0.552-6.0624.9591
B:1-S:0-0.571-6.3635.221
S:1-S:00.394-1.7332.5220.999
B:2-S:0-1.571-7.3634.220.991
S:2-S:0-1.571-5.9152.7720.954
B:3-S:0-1.811-4.0090.3870.191
S:3-S:0-0.123-2.4052.1581
S:1-B:10.966-4.4826.4140.999
B:2-B:1-1-8.6626.6621
S:2-B:1-1-7.6355.6351
B:3-B:1-1.239-6.7154.2370.997
S:3-B:10.448-5.0625.9591
B:2-S:1-1.966-7.4143.4820.954
S:2-S:1-1.966-5.841.9080.775
B:3-S:1-2.205-3.191-1.2190
S:3-S:1-0.518-1.6780.6420.87
S:2-B:20-6.6356.6351
B:3-B:2-0.239-5.7155.2371
S:3-B:21.448-4.0626.9590.993
B:3-S:2-0.239-4.1523.6741
S:3-S:21.448-2.5125.4090.951
S:3-B:31.6870.4032.9720.002

\begin{tabular}{lllllllll}
\hline
Tukey Honest Significant Difference Comparisons \tabularnewline
  & diff & lwr & upr & p adj \tabularnewline
S-B & 1.957 & 1.37 & 2.544 & 0 \tabularnewline
1-0 & 0.107 & -1.583 & 1.798 & 0.998 \tabularnewline
2-0 & -1.217 & -4.318 & 1.883 & 0.739 \tabularnewline
3-0 & -0.256 & -1.959 & 1.447 & 0.98 \tabularnewline
2-1 & -1.325 & -4.013 & 1.364 & 0.578 \tabularnewline
3-1 & -0.363 & -1.081 & 0.354 & 0.555 \tabularnewline
3-2 & 0.961 & -1.735 & 3.658 & 0.791 \tabularnewline
S:0-B:0 & -0.429 & -6.22 & 5.363 & 1 \tabularnewline
B:1-B:0 & -1 & -8.662 & 6.662 & 1 \tabularnewline
S:1-B:0 & -0.034 & -5.482 & 5.414 & 1 \tabularnewline
B:2-B:0 & -2 & -9.662 & 5.662 & 0.993 \tabularnewline
S:2-B:0 & -2 & -8.635 & 4.635 & 0.983 \tabularnewline
B:3-B:0 & -2.239 & -7.715 & 3.237 & 0.914 \tabularnewline
S:3-B:0 & -0.552 & -6.062 & 4.959 & 1 \tabularnewline
B:1-S:0 & -0.571 & -6.363 & 5.22 & 1 \tabularnewline
S:1-S:0 & 0.394 & -1.733 & 2.522 & 0.999 \tabularnewline
B:2-S:0 & -1.571 & -7.363 & 4.22 & 0.991 \tabularnewline
S:2-S:0 & -1.571 & -5.915 & 2.772 & 0.954 \tabularnewline
B:3-S:0 & -1.811 & -4.009 & 0.387 & 0.191 \tabularnewline
S:3-S:0 & -0.123 & -2.405 & 2.158 & 1 \tabularnewline
S:1-B:1 & 0.966 & -4.482 & 6.414 & 0.999 \tabularnewline
B:2-B:1 & -1 & -8.662 & 6.662 & 1 \tabularnewline
S:2-B:1 & -1 & -7.635 & 5.635 & 1 \tabularnewline
B:3-B:1 & -1.239 & -6.715 & 4.237 & 0.997 \tabularnewline
S:3-B:1 & 0.448 & -5.062 & 5.959 & 1 \tabularnewline
B:2-S:1 & -1.966 & -7.414 & 3.482 & 0.954 \tabularnewline
S:2-S:1 & -1.966 & -5.84 & 1.908 & 0.775 \tabularnewline
B:3-S:1 & -2.205 & -3.191 & -1.219 & 0 \tabularnewline
S:3-S:1 & -0.518 & -1.678 & 0.642 & 0.87 \tabularnewline
S:2-B:2 & 0 & -6.635 & 6.635 & 1 \tabularnewline
B:3-B:2 & -0.239 & -5.715 & 5.237 & 1 \tabularnewline
S:3-B:2 & 1.448 & -4.062 & 6.959 & 0.993 \tabularnewline
B:3-S:2 & -0.239 & -4.152 & 3.674 & 1 \tabularnewline
S:3-S:2 & 1.448 & -2.512 & 5.409 & 0.951 \tabularnewline
S:3-B:3 & 1.687 & 0.403 & 2.972 & 0.002 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=316167&T=3

[TABLE]
[ROW][C]Tukey Honest Significant Difference Comparisons[/C][/ROW]
[ROW][C] [/C][C]diff[/C][C]lwr[/C][C]upr[/C][C]p adj[/C][/ROW]
[ROW][C]S-B[/C][C]1.957[/C][C]1.37[/C][C]2.544[/C][C]0[/C][/ROW]
[ROW][C]1-0[/C][C]0.107[/C][C]-1.583[/C][C]1.798[/C][C]0.998[/C][/ROW]
[ROW][C]2-0[/C][C]-1.217[/C][C]-4.318[/C][C]1.883[/C][C]0.739[/C][/ROW]
[ROW][C]3-0[/C][C]-0.256[/C][C]-1.959[/C][C]1.447[/C][C]0.98[/C][/ROW]
[ROW][C]2-1[/C][C]-1.325[/C][C]-4.013[/C][C]1.364[/C][C]0.578[/C][/ROW]
[ROW][C]3-1[/C][C]-0.363[/C][C]-1.081[/C][C]0.354[/C][C]0.555[/C][/ROW]
[ROW][C]3-2[/C][C]0.961[/C][C]-1.735[/C][C]3.658[/C][C]0.791[/C][/ROW]
[ROW][C]S:0-B:0[/C][C]-0.429[/C][C]-6.22[/C][C]5.363[/C][C]1[/C][/ROW]
[ROW][C]B:1-B:0[/C][C]-1[/C][C]-8.662[/C][C]6.662[/C][C]1[/C][/ROW]
[ROW][C]S:1-B:0[/C][C]-0.034[/C][C]-5.482[/C][C]5.414[/C][C]1[/C][/ROW]
[ROW][C]B:2-B:0[/C][C]-2[/C][C]-9.662[/C][C]5.662[/C][C]0.993[/C][/ROW]
[ROW][C]S:2-B:0[/C][C]-2[/C][C]-8.635[/C][C]4.635[/C][C]0.983[/C][/ROW]
[ROW][C]B:3-B:0[/C][C]-2.239[/C][C]-7.715[/C][C]3.237[/C][C]0.914[/C][/ROW]
[ROW][C]S:3-B:0[/C][C]-0.552[/C][C]-6.062[/C][C]4.959[/C][C]1[/C][/ROW]
[ROW][C]B:1-S:0[/C][C]-0.571[/C][C]-6.363[/C][C]5.22[/C][C]1[/C][/ROW]
[ROW][C]S:1-S:0[/C][C]0.394[/C][C]-1.733[/C][C]2.522[/C][C]0.999[/C][/ROW]
[ROW][C]B:2-S:0[/C][C]-1.571[/C][C]-7.363[/C][C]4.22[/C][C]0.991[/C][/ROW]
[ROW][C]S:2-S:0[/C][C]-1.571[/C][C]-5.915[/C][C]2.772[/C][C]0.954[/C][/ROW]
[ROW][C]B:3-S:0[/C][C]-1.811[/C][C]-4.009[/C][C]0.387[/C][C]0.191[/C][/ROW]
[ROW][C]S:3-S:0[/C][C]-0.123[/C][C]-2.405[/C][C]2.158[/C][C]1[/C][/ROW]
[ROW][C]S:1-B:1[/C][C]0.966[/C][C]-4.482[/C][C]6.414[/C][C]0.999[/C][/ROW]
[ROW][C]B:2-B:1[/C][C]-1[/C][C]-8.662[/C][C]6.662[/C][C]1[/C][/ROW]
[ROW][C]S:2-B:1[/C][C]-1[/C][C]-7.635[/C][C]5.635[/C][C]1[/C][/ROW]
[ROW][C]B:3-B:1[/C][C]-1.239[/C][C]-6.715[/C][C]4.237[/C][C]0.997[/C][/ROW]
[ROW][C]S:3-B:1[/C][C]0.448[/C][C]-5.062[/C][C]5.959[/C][C]1[/C][/ROW]
[ROW][C]B:2-S:1[/C][C]-1.966[/C][C]-7.414[/C][C]3.482[/C][C]0.954[/C][/ROW]
[ROW][C]S:2-S:1[/C][C]-1.966[/C][C]-5.84[/C][C]1.908[/C][C]0.775[/C][/ROW]
[ROW][C]B:3-S:1[/C][C]-2.205[/C][C]-3.191[/C][C]-1.219[/C][C]0[/C][/ROW]
[ROW][C]S:3-S:1[/C][C]-0.518[/C][C]-1.678[/C][C]0.642[/C][C]0.87[/C][/ROW]
[ROW][C]S:2-B:2[/C][C]0[/C][C]-6.635[/C][C]6.635[/C][C]1[/C][/ROW]
[ROW][C]B:3-B:2[/C][C]-0.239[/C][C]-5.715[/C][C]5.237[/C][C]1[/C][/ROW]
[ROW][C]S:3-B:2[/C][C]1.448[/C][C]-4.062[/C][C]6.959[/C][C]0.993[/C][/ROW]
[ROW][C]B:3-S:2[/C][C]-0.239[/C][C]-4.152[/C][C]3.674[/C][C]1[/C][/ROW]
[ROW][C]S:3-S:2[/C][C]1.448[/C][C]-2.512[/C][C]5.409[/C][C]0.951[/C][/ROW]
[ROW][C]S:3-B:3[/C][C]1.687[/C][C]0.403[/C][C]2.972[/C][C]0.002[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=316167&T=3

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

As an alternative you can also use a QR Code:  

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

Tukey Honest Significant Difference Comparisons
difflwruprp adj
S-B1.9571.372.5440
1-00.107-1.5831.7980.998
2-0-1.217-4.3181.8830.739
3-0-0.256-1.9591.4470.98
2-1-1.325-4.0131.3640.578
3-1-0.363-1.0810.3540.555
3-20.961-1.7353.6580.791
S:0-B:0-0.429-6.225.3631
B:1-B:0-1-8.6626.6621
S:1-B:0-0.034-5.4825.4141
B:2-B:0-2-9.6625.6620.993
S:2-B:0-2-8.6354.6350.983
B:3-B:0-2.239-7.7153.2370.914
S:3-B:0-0.552-6.0624.9591
B:1-S:0-0.571-6.3635.221
S:1-S:00.394-1.7332.5220.999
B:2-S:0-1.571-7.3634.220.991
S:2-S:0-1.571-5.9152.7720.954
B:3-S:0-1.811-4.0090.3870.191
S:3-S:0-0.123-2.4052.1581
S:1-B:10.966-4.4826.4140.999
B:2-B:1-1-8.6626.6621
S:2-B:1-1-7.6355.6351
B:3-B:1-1.239-6.7154.2370.997
S:3-B:10.448-5.0625.9591
B:2-S:1-1.966-7.4143.4820.954
S:2-S:1-1.966-5.841.9080.775
B:3-S:1-2.205-3.191-1.2190
S:3-S:1-0.518-1.6780.6420.87
S:2-B:20-6.6356.6351
B:3-B:2-0.239-5.7155.2371
S:3-B:21.448-4.0626.9590.993
B:3-S:2-0.239-4.1523.6741
S:3-S:21.448-2.5125.4090.951
S:3-B:31.6870.4032.9720.002







Levenes Test for Homogeneity of Variance
DfF valuePr(>F)
Group72.9590.006
167

\begin{tabular}{lllllllll}
\hline
Levenes Test for Homogeneity of Variance \tabularnewline
  & Df & F value & Pr(>F) \tabularnewline
Group & 7 & 2.959 & 0.006 \tabularnewline
  & 167 &   &   \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=316167&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]7[/C][C]2.959[/C][C]0.006[/C][/ROW]
[ROW][C] [/C][C]167[/C][C] [/C][C] [/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=316167&T=4

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=316167&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)
Group72.9590.006
167



Parameters (Session):
Parameters (R input):
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')