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, 24 Nov 2011 09:12:08 -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/24/t1322143961809vl0eqkyrbse4.htm/, Retrieved Fri, 19 Apr 2024 05:02:33 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=146841, Retrieved Fri, 19 Apr 2024 05:02:33 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact65
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
-       [Two-Way ANOVA] [Anova] [2011-11-24 14:12:08] [c38c32477296496b546025b407c5c736] [Current]
Feedback Forum

Post a new message
Dataseries X:
888	63031	51	256
545	66751	24	160
186	7176	17	70
1405	78306	66	360
2047	137944	85	721
3617	260469	128	935
843	68781	34	287
643	80226	32	149
1181	73226	33	311
1835	178519	64	617
855	66476	35	262
1245	98606	46	385
993	50001	69	369
1684	91093	60	558
741	73884	24	220
854	72377	38	313
948	69388	33	229
331	15629	20	88
1602	71693	54	494
510	19896	16	153
628	39403	37	234
1279	99933	51	361
767	56088	28	280
1155	62006	31	331
1120	81665	51	378
622	65223	12	227
1203	88794	98	396
745	90642	53	179
1535	203699	61	509
1234	99340	25	504
757	56695	28	225
1087	108143	23	366
1105	58313	60	341
592	29101	40	171
1305	113060	29	437
0	0	0	0
705	65773	33	313
1188	67047	34	366
1110	41953	21	232
1094	109835	35	389
1061	82577	33	340
748	59588	26	316
404	40064	12	140
1076	70227	45	419
673	60437	29	226
516	47000	35	161
354	40295	13	103
1011	103397	54	356
890	78982	39	293
1066	60206	27	414
518	39887	21	156
696	49791	35	189
1095	129283	44	442
928	104816	44	321
1008	101395	33	367
951	72824	30	309
770	75328	25	232
438	33891	11	137
568	62164	37	194
614	28266	24	220
499	35093	21	149
823	35252	34	306
540	36977	19	178
475	42406	18	145
433	56353	12	144
818	58817	23	270
1173	76053	43	301
1719	70872	48	501
549	42372	20	153
110	15428	11	31
1594	114177	73	500
622	53544	26	199
656	51379	33	242
920	40756	39	265
833	46357	20	293
497	17799	20	141
864	71154	30	234
994	58305	38	336
443	27454	16	124
615	34323	34	241
524	44761	32	127
899	113862	27	327
556	35027	16	175
896	62396	22	331
515	29613	25	176
894	65559	28	281
1313	109788	108	291
475	26263	27	131
446	39773	23	148
639	53398	22	194
795	56435	23	300
1243	77283	45	370
558	71738	29	187
573	48096	29	210
439	25214	22	185
1307	119332	63	445
765	79201	27	234
222	19349	11	67
935	73984	53	300
821	54133	35	336
317	21623	16	116
425	25497	11	141
711	69535	38	236
363	30709	21	98
427	37043	23	97
463	24716	13	152
545	54865	16	132
368	27246	18	97
0	0	0	0
596	38814	13	165
478	27646	31	153
713	65373	18	226
639	43021	34	182
477	43116	40	172
38	3058	4	1
0	0	0	0
592	96347	24	196
665	45666	27	260
1007	68923	49	291
495	45266	22	183
778	43410	19	292
875	83842	34	257
490	39296	21	141
682	35223	23	189
484	39841	18	129
285	19764	12	75
934	59975	20	301
553	64589	15	204
753	63339	14	257
256	11796	9	79
80	7627	8	25
618	68998	30	217
41	6836	3	11
497	28834	14	209
42	5118	3	6
347	20898	13	115
0	0	0	0
441	42690	18	167
281	14507	11	75
81	7131	4	27
61	4194	11	14
313	21416	9	96
326	30591	12	95
553	42419	9	228




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

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=146841&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 time0 seconds
R Server'Gwilym Jenkins' @ jenkins.wessa.net



Parameters (Session):
par4 = FALSE ;
Parameters (R input):
par1 = ; par2 = ; par3 = ; 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')