Free Statistics

of Irreproducible Research!

Author's title

Author*The author of this computation has been verified*
R Software Modulerwasp_twosampletests_mean.wasp
Title produced by softwarePaired and Unpaired Two Samples Tests about the Mean
Date of computationWed, 13 Dec 2017 11:40:38 +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/2017/Dec/13/t15131710862b0n321zy8gzqph.htm/, Retrieved Wed, 15 May 2024 16:00:07 +0000
Statistical Computations at FreeStatistics.org, Office for Research Development and Education, URL https://freestatistics.org/blog/index.php?pk=309286, Retrieved Wed, 15 May 2024 16:00:07 +0000
QR Codes:

Original text written by user:
IsPrivate?No (this computation is public)
User-defined keywords
Estimated Impact73
Family? (F = Feedback message, R = changed R code, M = changed R Module, P = changed Parameters, D = changed Data)
-       [Paired and Unpaired Two Samples Tests about the Mean] [] [2017-12-13 10:40:38] [6b1874e4714eefd7b92809f59303eb6f] [Current]
Feedback Forum

Post a new message
Dataseries X:
58.5	55.5
59.8	63
64.6	77.2
62.2	71.1
68	90.1
64.3	91.5
58.9	76.1
64.8	87.8
67.5	81
76.2	77.2
73.7	73.8
70.4	68.9
67.7	68.4
63.7	65.2
72.4	78.7
66	77
70.1	97.6
70.4	88.1
66.6	98.7
72.6	93.4
74	68
79	87.9
76.1	75.8
72.3	66.3
71.6	68.4
67.2	71.3
73.8	77.4
70.8	87.1
71.4	88.5
70.4	85.9
70.7	92.7
70.6	88.5
75.5	80.2
82.1	81.8
74.3	70.4
76.3	82.2
74.5	72.8
71.1	69
73.3	83
73.8	92.4
69	92.3
71.1	100.5
71.9	106.9
69	99.5
77.3	85.9
82.8	92.6
74	77.4
77.6	84.1
72.3	75.3
70.7	73.8
81	100.1
76.4	90.7
72.3	96.5
79.5	111.8
73.3	97.4
74.5	100.8
82.7	93.7
83.8	82
81.6	86
85.5	84.3
76.7	73.1
71.8	75.4
80.2	97.9
76.8	97.5
76.1	106
80.7	112.8
71.3	99.5
80.9	100.8
85	102.9
84.5	88.8
87.7	91.3
87.7	88.3
80.2	77.4
74.4	80.5
85.8	96.7
77	93.8
84.5	105
83.6	117.1
77.7	111.1
85.7	105.8
87.9	95.7
93.7	97.1
92.3	91
87	90.9
89.1	83.5
81.3	82.3
92.7	101.7
83.9	108.3
87.3	114
89.1	118.2
86.9	103.4
91.7	106.8
93	95.4
105.3	101.8
101.6	95.6
94.2	94.8
100.5	94
95.8	82.4
95.8	95.8
102.1	106.7
96	114.1
96.8	103.9
98.9	117.4
93.4	105.9
105.5	101.7
110.9	98.7
98.6	91.3
102.6	102.3
93.5	80.5
90.8	86.7
99.7	102.6
97.8	107.3
91.1	108
98.1	124.3
96	117.1
93.5	103.9
101.2	104.7
105.2	95.9
98.9	94.2
101.3	102.7
92.1	70.3
90.6	90.2
105.4	107.3
98.4	104.6
92.7	102.7
101.2	124.5
93.4	117.8
98.3	104.2
104.3	99.9
107	91.5
107.7	95.7
108.9	91.4
99.6	86.2
96.1	91.5
109	115.5
99.5	113.9
104.6	131.9
99.9	121.2
94.1	105.2
105.3	107.5
110.4	113.8
110.5	100.5
110	104.8
108.5	103.8
104.3	93.1
101.2	106.2
109.2	117.5
99.6	109.9
105.6	123.6
106.2	131.7
102.2	111
107.5	122
105.8	110.9
120.5	108
113.2	103.6
104.3	107.3
107.7	94.4
99.2	85.2
105.1	113.2
104.3	111.7
106.1	124.3
100.8	124
106.7	133.4
101.6	112.6
104.4	115.8
114.8	112.3
105.4	103.6
104	111.4
102	95.1
96.5	93.4
102.3	117.3
105.3	121.5
101.9	123.1
102.2	139.3
102.8	125.8
100.4	108.6
110.7	121
116.4	111.6
106	99.7
109.2	116.7
103	90.3
99.8	90.4
109.8	117.3
107.3	121.6
101.2	114.6
111.8	133.3
106.9	127.4
103.5	115
113.1	112.6
119.4	108.3
113.3	107.6
115	109
104.7	89
107.2	102.5
116.6	124.5
111.3	124.2
111.4	130.8
115	138.7
102.4	127.6
111.4	130.9
113.2	136.9
112.9	125.2
114.2	131.3
115.6	124.1
107.1	103.2
102.3	118.1
117.9	136.5
105.8	117.8
114.3	145.1
113.1	158.8
102.9	136.9
112.2	132.7




Summary of computational transaction
Raw Input view raw input (R code)
Raw Outputview raw output of R engine
Computing time2 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 time2 seconds \tabularnewline
R ServerBig Analytics Cloud Computing Center \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=309286&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]2 seconds[/C][/ROW] [ROW]R Server[/C]Big Analytics Cloud Computing Center[/C][/ROW] [/TABLE] Source: https://freestatistics.org/blog/index.php?pk=309286&T=0

Globally Unique Identifier (entire table): ba.freestatistics.org/blog/index.php?pk=309286&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 time2 seconds
R ServerBig Analytics Cloud Computing Center







Two Sample t-test (paired)
Difference: Mean1 - Mean28.78490566037736
t-stat9.90668309626105
df211
p-value3.04950929677865e-19
H0 value0
Alternativetwo.sided
CI Level0.95
CI[7.03685068694797,10.5329606338067]
F-test to compare two variances
F-stat1.33566656341762
df211
p-value0.0360841219575045
H0 value1
Alternativetwo.sided
CI Level0.95
CI[1.01901960560082,1.75070740427999]

\begin{tabular}{lllllllll}
\hline
Two Sample t-test (paired) \tabularnewline
Difference: Mean1 - Mean2 & 8.78490566037736 \tabularnewline
t-stat & 9.90668309626105 \tabularnewline
df & 211 \tabularnewline
p-value & 3.04950929677865e-19 \tabularnewline
H0 value & 0 \tabularnewline
Alternative & two.sided \tabularnewline
CI Level & 0.95 \tabularnewline
CI & [7.03685068694797,10.5329606338067] \tabularnewline
F-test to compare two variances \tabularnewline
F-stat & 1.33566656341762 \tabularnewline
df & 211 \tabularnewline
p-value & 0.0360841219575045 \tabularnewline
H0 value & 1 \tabularnewline
Alternative & two.sided \tabularnewline
CI Level & 0.95 \tabularnewline
CI & [1.01901960560082,1.75070740427999] \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=309286&T=1

[TABLE]
[ROW][C]Two Sample t-test (paired)[/C][/ROW]
[ROW][C]Difference: Mean1 - Mean2[/C][C]8.78490566037736[/C][/ROW]
[ROW][C]t-stat[/C][C]9.90668309626105[/C][/ROW]
[ROW][C]df[/C][C]211[/C][/ROW]
[ROW][C]p-value[/C][C]3.04950929677865e-19[/C][/ROW]
[ROW][C]H0 value[/C][C]0[/C][/ROW]
[ROW][C]Alternative[/C][C]two.sided[/C][/ROW]
[ROW][C]CI Level[/C][C]0.95[/C][/ROW]
[ROW][C]CI[/C][C][7.03685068694797,10.5329606338067][/C][/ROW]
[ROW][C]F-test to compare two variances[/C][/ROW]
[ROW][C]F-stat[/C][C]1.33566656341762[/C][/ROW]
[ROW][C]df[/C][C]211[/C][/ROW]
[ROW][C]p-value[/C][C]0.0360841219575045[/C][/ROW]
[ROW][C]H0 value[/C][C]1[/C][/ROW]
[ROW][C]Alternative[/C][C]two.sided[/C][/ROW]
[ROW][C]CI Level[/C][C]0.95[/C][/ROW]
[ROW][C]CI[/C][C][1.01901960560082,1.75070740427999][/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=309286&T=1

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

As an alternative you can also use a QR Code:  

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

Two Sample t-test (paired)
Difference: Mean1 - Mean28.78490566037736
t-stat9.90668309626105
df211
p-value3.04950929677865e-19
H0 value0
Alternativetwo.sided
CI Level0.95
CI[7.03685068694797,10.5329606338067]
F-test to compare two variances
F-stat1.33566656341762
df211
p-value0.0360841219575045
H0 value1
Alternativetwo.sided
CI Level0.95
CI[1.01901960560082,1.75070740427999]







Welch Two Sample t-test (paired)
Difference: Mean1 - Mean28.78490566037736
t-stat9.90668309626105
df211
p-value3.04950929677865e-19
H0 value0
Alternativetwo.sided
CI Level0.95
CI[7.03685068694797,10.5329606338067]

\begin{tabular}{lllllllll}
\hline
Welch Two Sample t-test (paired) \tabularnewline
Difference: Mean1 - Mean2 & 8.78490566037736 \tabularnewline
t-stat & 9.90668309626105 \tabularnewline
df & 211 \tabularnewline
p-value & 3.04950929677865e-19 \tabularnewline
H0 value & 0 \tabularnewline
Alternative & two.sided \tabularnewline
CI Level & 0.95 \tabularnewline
CI & [7.03685068694797,10.5329606338067] \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=309286&T=2

[TABLE]
[ROW][C]Welch Two Sample t-test (paired)[/C][/ROW]
[ROW][C]Difference: Mean1 - Mean2[/C][C]8.78490566037736[/C][/ROW]
[ROW][C]t-stat[/C][C]9.90668309626105[/C][/ROW]
[ROW][C]df[/C][C]211[/C][/ROW]
[ROW][C]p-value[/C][C]3.04950929677865e-19[/C][/ROW]
[ROW][C]H0 value[/C][C]0[/C][/ROW]
[ROW][C]Alternative[/C][C]two.sided[/C][/ROW]
[ROW][C]CI Level[/C][C]0.95[/C][/ROW]
[ROW][C]CI[/C][C][7.03685068694797,10.5329606338067][/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=309286&T=2

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

As an alternative you can also use a QR Code:  

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

Welch Two Sample t-test (paired)
Difference: Mean1 - Mean28.78490566037736
t-stat9.90668309626105
df211
p-value3.04950929677865e-19
H0 value0
Alternativetwo.sided
CI Level0.95
CI[7.03685068694797,10.5329606338067]







Wilcoxon Signed-Rank Test with continuity correction (paired)
W18427.5
p-value3.39382508759366e-16
H0 value0
Alternativetwo.sided
Kolmogorov-Smirnov Test to compare Distributions of two Samples
KS Statistic0.193396226415094
p-value0.000720116104643287
Kolmogorov-Smirnov Test to compare Distributional Shape of two Samples
KS Statistic0.117924528301887
p-value0.104861983852334

\begin{tabular}{lllllllll}
\hline
Wilcoxon Signed-Rank Test with continuity correction (paired) \tabularnewline
W & 18427.5 \tabularnewline
p-value & 3.39382508759366e-16 \tabularnewline
H0 value & 0 \tabularnewline
Alternative & two.sided \tabularnewline
Kolmogorov-Smirnov Test to compare Distributions of two Samples \tabularnewline
KS Statistic & 0.193396226415094 \tabularnewline
p-value & 0.000720116104643287 \tabularnewline
Kolmogorov-Smirnov Test to compare Distributional Shape of two Samples \tabularnewline
KS Statistic & 0.117924528301887 \tabularnewline
p-value & 0.104861983852334 \tabularnewline
\hline
\end{tabular}
%Source: https://freestatistics.org/blog/index.php?pk=309286&T=3

[TABLE]
[ROW][C]Wilcoxon Signed-Rank Test with continuity correction (paired)[/C][/ROW]
[ROW][C]W[/C][C]18427.5[/C][/ROW]
[ROW][C]p-value[/C][C]3.39382508759366e-16[/C][/ROW]
[ROW][C]H0 value[/C][C]0[/C][/ROW]
[ROW][C]Alternative[/C][C]two.sided[/C][/ROW]
[ROW][C]Kolmogorov-Smirnov Test to compare Distributions of two Samples[/C][/ROW]
[ROW][C]KS Statistic[/C][C]0.193396226415094[/C][/ROW]
[ROW][C]p-value[/C][C]0.000720116104643287[/C][/ROW]
[ROW][C]Kolmogorov-Smirnov Test to compare Distributional Shape of two Samples[/C][/ROW]
[ROW][C]KS Statistic[/C][C]0.117924528301887[/C][/ROW]
[ROW][C]p-value[/C][C]0.104861983852334[/C][/ROW]
[/TABLE]
Source: https://freestatistics.org/blog/index.php?pk=309286&T=3

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

As an alternative you can also use a QR Code:  

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

Wilcoxon Signed-Rank Test with continuity correction (paired)
W18427.5
p-value3.39382508759366e-16
H0 value0
Alternativetwo.sided
Kolmogorov-Smirnov Test to compare Distributions of two Samples
KS Statistic0.193396226415094
p-value0.000720116104643287
Kolmogorov-Smirnov Test to compare Distributional Shape of two Samples
KS Statistic0.117924528301887
p-value0.104861983852334



Parameters (Session):
par1 = 2 ; par2 = 1 ; par3 = 0.95 ; par4 = two.sided ; par5 = paired ; par6 = 0 ;
Parameters (R input):
par1 = 2 ; par2 = 1 ; par3 = 0.95 ; par4 = two.sided ; par5 = paired ; par6 = 0 ;
R code (references can be found in the software module):
par6 <- '0'
par5 <- 'paired'
par4 <- 'two.sided'
par3 <- '0.05'
par2 <- '1'
par1 <- '2'
par1 <- as.numeric(par1) #column number of first sample
par2 <- as.numeric(par2) #column number of second sample
par3 <- as.numeric(par3) #confidence (= 1 - alpha)
if (par5 == 'unpaired') paired <- FALSE else paired <- TRUE
par6 <- as.numeric(par6) #H0
z <- t(y)
if (par1 == par2) stop('Please, select two different column numbers')
if (par1 < 1) stop('Please, select a column number greater than zero for the first sample')
if (par2 < 1) stop('Please, select a column number greater than zero for the second sample')
if (par1 > length(z[1,])) stop('The column number for the first sample should be smaller')
if (par2 > length(z[1,])) stop('The column number for the second sample should be smaller')
if (par3 <= 0) stop('The confidence level should be larger than zero')
if (par3 >= 1) stop('The confidence level should be smaller than zero')
(r.t <- t.test(z[,par1],z[,par2],var.equal=TRUE,alternative=par4,paired=paired,mu=par6,conf.level=par3))
(v.t <- var.test(z[,par1],z[,par2],conf.level=par3))
(r.w <- t.test(z[,par1],z[,par2],var.equal=FALSE,alternative=par4,paired=paired,mu=par6,conf.level=par3))
(w.t <- wilcox.test(z[,par1],z[,par2],alternative=par4,paired=paired,mu=par6,conf.level=par3))
(ks.t <- ks.test(z[,par1],z[,par2],alternative=par4))
m1 <- mean(z[,par1],na.rm=T)
m2 <- mean(z[,par2],na.rm=T)
mdiff <- m1 - m2
newsam1 <- z[!is.na(z[,par1]),par1]
newsam2 <- z[,par2]+mdiff
newsam2 <- newsam2[!is.na(newsam2)]
(ks1.t <- ks.test(newsam1,newsam2,alternative=par4))
mydf <- data.frame(cbind(z[,par1],z[,par2]))
colnames(mydf) <- c('Variable 1','Variable 2')
bitmap(file='test1.png')
boxplot(mydf, notch=TRUE, ylab='value',main=main)
dev.off()
bitmap(file='test2.png')
qqnorm(z[,par1],main='Normal QQplot - Variable 1')
qqline(z[,par1])
dev.off()
bitmap(file='test3.png')
qqnorm(z[,par2],main='Normal QQplot - Variable 2')
qqline(z[,par2])
dev.off()
load(file='createtable')
a<-table.start()
a<-table.row.start(a)
a<-table.element(a,paste('Two Sample t-test (',par5,')',sep=''),2,TRUE)
a<-table.row.end(a)
if(!paired){
a<-table.row.start(a)
a<-table.element(a,'Mean of Sample 1',header=TRUE)
a<-table.element(a,r.t$estimate[[1]])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Mean of Sample 2',header=TRUE)
a<-table.element(a,r.t$estimate[[2]])
a<-table.row.end(a)
} else {
a<-table.row.start(a)
a<-table.element(a,'Difference: Mean1 - Mean2',header=TRUE)
a<-table.element(a,r.t$estimate)
a<-table.row.end(a)
}
a<-table.row.start(a)
a<-table.element(a,'t-stat',header=TRUE)
a<-table.element(a,r.t$statistic[[1]])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'df',header=TRUE)
a<-table.element(a,r.t$parameter[[1]])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'p-value',header=TRUE)
a<-table.element(a,r.t$p.value)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'H0 value',header=TRUE)
a<-table.element(a,r.t$null.value[[1]])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Alternative',header=TRUE)
a<-table.element(a,r.t$alternative)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'CI Level',header=TRUE)
a<-table.element(a,attr(r.t$conf.int,'conf.level'))
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'CI',header=TRUE)
a<-table.element(a,paste('[',r.t$conf.int[1],',',r.t$conf.int[2],']',sep=''))
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'F-test to compare two variances',2,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'F-stat',header=TRUE)
a<-table.element(a,v.t$statistic[[1]])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'df',header=TRUE)
a<-table.element(a,v.t$parameter[[1]])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'p-value',header=TRUE)
a<-table.element(a,v.t$p.value)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'H0 value',header=TRUE)
a<-table.element(a,v.t$null.value[[1]])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Alternative',header=TRUE)
a<-table.element(a,v.t$alternative)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'CI Level',header=TRUE)
a<-table.element(a,attr(v.t$conf.int,'conf.level'))
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'CI',header=TRUE)
a<-table.element(a,paste('[',v.t$conf.int[1],',',v.t$conf.int[2],']',sep=''))
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,paste('Welch Two Sample t-test (',par5,')',sep=''),2,TRUE)
a<-table.row.end(a)
if(!paired){
a<-table.row.start(a)
a<-table.element(a,'Mean of Sample 1',header=TRUE)
a<-table.element(a,r.w$estimate[[1]])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Mean of Sample 2',header=TRUE)
a<-table.element(a,r.w$estimate[[2]])
a<-table.row.end(a)
} else {
a<-table.row.start(a)
a<-table.element(a,'Difference: Mean1 - Mean2',header=TRUE)
a<-table.element(a,r.w$estimate)
a<-table.row.end(a)
}
a<-table.row.start(a)
a<-table.element(a,'t-stat',header=TRUE)
a<-table.element(a,r.w$statistic[[1]])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'df',header=TRUE)
a<-table.element(a,r.w$parameter[[1]])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'p-value',header=TRUE)
a<-table.element(a,r.w$p.value)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'H0 value',header=TRUE)
a<-table.element(a,r.w$null.value[[1]])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Alternative',header=TRUE)
a<-table.element(a,r.w$alternative)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'CI Level',header=TRUE)
a<-table.element(a,attr(r.w$conf.int,'conf.level'))
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'CI',header=TRUE)
a<-table.element(a,paste('[',r.w$conf.int[1],',',r.w$conf.int[2],']',sep=''))
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable1.tab')
a<-table.start()
a<-table.row.start(a)
myWlabel <- 'Wilcoxon Signed-Rank Test'
if (par5=='unpaired') myWlabel = 'Wilcoxon Rank-Sum Test (Mann–Whitney U test)'
a<-table.element(a,paste(myWlabel,' with continuity correction (',par5,')',sep=''),2,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'W',header=TRUE)
a<-table.element(a,w.t$statistic[[1]])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'p-value',header=TRUE)
a<-table.element(a,w.t$p.value)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'H0 value',header=TRUE)
a<-table.element(a,w.t$null.value[[1]])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Alternative',header=TRUE)
a<-table.element(a,w.t$alternative)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Kolmogorov-Smirnov Test to compare Distributions of two Samples',2,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'KS Statistic',header=TRUE)
a<-table.element(a,ks.t$statistic[[1]])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'p-value',header=TRUE)
a<-table.element(a,ks.t$p.value)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'Kolmogorov-Smirnov Test to compare Distributional Shape of two Samples',2,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'KS Statistic',header=TRUE)
a<-table.element(a,ks1.t$statistic[[1]])
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'p-value',header=TRUE)
a<-table.element(a,ks1.t$p.value)
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file='mytable2.tab')