Send output to:
Browser Blue - Charts White
Browser Black/White
CSV
Data X:
14 41 38 18 39 32 11 30 35 12 31 33 16 34 37 18 35 29 14 39 31 14 34 36 15 36 35 15 37 38 17 38 31 19 36 34 10 38 35 16 39 38 18 33 37 14 32 33 14 36 32 17 38 38 14 39 38 16 32 32 18 32 33 11 31 31 14 39 38 12 37 39 17 39 32 9 41 32 16 36 35 14 33 37 15 33 33 11 34 33 16 31 28 13 27 32 17 37 31 15 34 37 14 34 30 16 32 33 9 29 31 15 36 33 17 29 31 13 35 33 15 37 32 16 34 33 16 38 32 12 35 33 12 38 28 11 37 35 15 38 39 15 33 34 17 36 38 13 38 32 16 32 38 14 32 30 11 32 33 12 34 38 12 32 32 15 37 32 16 39 34 15 29 34 12 37 36 12 35 34 8 30 28 13 38 34 11 34 35 14 31 35 15 34 31 10 35 37 11 36 35 12 30 27 15 39 40 15 35 37 14 38 36 16 31 38 15 34 39 15 38 41 13 34 27 12 39 30 17 37 37 13 34 31 15 28 31 13 37 27 15 33 36 16 37 38 15 35 37 16 37 33 15 32 34 14 33 31 15 38 39 14 33 34 13 29 32 7 33 33 17 31 36 13 36 32 15 35 41 14 32 28 13 29 30 16 39 36 12 37 35 14 35 31 17 37 34 15 32 36 17 38 36 12 37 35 16 36 37 11 32 28 15 33 39 9 40 32 16 38 35 15 41 39 10 36 35 10 43 42 15 30 34 11 31 33 13 32 41 14 32 33 18 37 34 16 37 32 14 33 40 14 34 40 14 33 35 14 38 36 12 33 37 14 31 27 15 38 39 15 37 38 15 33 31 13 31 33 17 39 32 17 44 39 19 33 36 15 35 33 13 32 33 9 28 32 15 40 37 15 27 30 15 37 38 16 32 29 11 28 22 14 34 35 11 30 35 15 35 34 13 31 35 15 32 34 16 30 34 14 30 35 15 31 23 16 40 31 16 32 27 11 36 36 12 32 31 9 35 32 16 38 39 13 42 37 16 34 38 12 35 39 9 35 34 13 33 31 13 36 32 14 32 37 19 33 36 13 34 32 12 32 35 13 34 36
Names of X columns:
Happ Conn Sep
Factor 1
Factor 2
Type of test to use
(?)
Pearson Chi-Squared
Pearson Chi-Squared
Exact Pearson Chi-Squared by Simulation
McNemar Chi-Squared
Fisher Exact Test
Chart options
Title:
R Code
library(vcd) cat1 <- as.numeric(par1) # cat2<- as.numeric(par2) # simulate.p.value=FALSE if (par3 == 'Exact Pearson Chi-Squared by Simulation') simulate.p.value=TRUE x <- t(x) (z <- array(unlist(x),dim=c(length(x[,1]),length(x[1,])))) (table1 <- table(z[,cat1],z[,cat2])) (V1<-dimnames(y)[[1]][cat1]) (V2<-dimnames(y)[[1]][cat2]) bitmap(file='pic1.png') assoc(ftable(z[,cat1],z[,cat2],row.vars=1,dnn=c(V1,V2)),shade=T) dev.off() load(file='createtable') a<-table.start() a<-table.row.start(a) a<-table.element(a,'Tabulation of Results',ncol(table1)+1,TRUE) a<-table.row.end(a) a<-table.row.start(a) a<-table.element(a,paste(V1,' x ', V2),ncol(table1)+1,TRUE) a<-table.row.end(a) a<-table.row.start(a) a<-table.element(a, ' ', 1,TRUE) for(nc in 1:ncol(table1)){ a<-table.element(a, colnames(table1)[nc], 1, TRUE) } a<-table.row.end(a) for(nr in 1:nrow(table1) ){ a<-table.element(a, rownames(table1)[nr], 1, TRUE) for(nc in 1:ncol(table1) ){ a<-table.element(a, table1[nr, nc], 1, FALSE) } a<-table.row.end(a) } a<-table.end(a) table.save(a,file='mytable.tab') (cst<-chisq.test(table1, simulate.p.value=simulate.p.value) ) if (par3 == 'McNemar Chi-Squared') { (cst <- mcnemar.test(table1)) } if (par3=='Fisher Exact Test') { (cst <- fisher.test(table1)) } if ((par3 != 'McNemar Chi-Squared') & (par3 != 'Fisher Exact Test')) { a<-table.start() a<-table.row.start(a) a<-table.element(a,'Tabulation of Expected Results',ncol(table1)+1,TRUE) a<-table.row.end(a) a<-table.row.start(a) a<-table.element(a,paste(V1,' x ', V2),ncol(table1)+1,TRUE) a<-table.row.end(a) a<-table.row.start(a) a<-table.element(a, ' ', 1,TRUE) for(nc in 1:ncol(table1)){ a<-table.element(a, colnames(table1)[nc], 1, TRUE) } a<-table.row.end(a) for(nr in 1:nrow(table1) ){ a<-table.element(a, rownames(table1)[nr], 1, TRUE) for(nc in 1:ncol(table1) ){ a<-table.element(a, round(cst$expected[nr, nc], digits=2), 1, FALSE) } 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,'Statistical Results',2,TRUE) a<-table.row.end(a) a<-table.row.start(a) a<-table.element(a, cst$method, 2,TRUE) a<-table.row.end(a) a<-table.row.start(a) if (par3=='Pearson Chi-Squared') a<-table.element(a, 'Pearson Chi Square Statistic', 1, TRUE) if (par3=='Exact Pearson Chi-Squared by Simulation') a<-table.element(a, 'Exact Pearson Chi Square Statistic', 1, TRUE) if (par3=='McNemar Chi-Squared') a<-table.element(a, 'McNemar Chi Square Statistic', 1, TRUE) if (par3=='Fisher Exact Test') a<-table.element(a, 'Odds Ratio', 1, TRUE) if (par3=='Fisher Exact Test') { if ((ncol(table1) == 2) & (nrow(table1) == 2)) { a<-table.element(a, round(cst$estimate, digits=2), 1,FALSE) } else { a<-table.element(a, '--', 1,FALSE) } } else { a<-table.element(a, round(cst$statistic, digits=2), 1,FALSE) } a<-table.row.end(a) if(!simulate.p.value){ if(par3!='Fisher Exact Test') { a<-table.row.start(a) a<-table.element(a, 'Degrees of Freedom', 1, TRUE) a<-table.element(a, cst$parameter, 1,FALSE) a<-table.row.end(a) } } a<-table.row.start(a) a<-table.element(a, 'P value', 1, TRUE) a<-table.element(a, round(cst$p.value, digits=2), 1,FALSE) a<-table.row.end(a) a<-table.end(a) table.save(a,file='mytable2.tab')
Compute
Summary of computational transaction
Raw Input
view raw input (R code)
Raw Output
view raw output of R engine
Computing time
0 seconds
R Server
Big Analytics Cloud Computing Center
Click here to blog (archive) this computation