R version 3.0.2 (2013-09-25) -- "Frisbee Sailing" Copyright (C) 2013 The R Foundation for Statistical Computing Platform: i686-pc-linux-gnu (32-bit) R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for an HTML browser interface to help. Type 'q()' to quit R. > x <- c(185,188,175,190,198,185,196,183,185,188,196,188,183,208,183,178,178,180,183,203,203,178,190,190,190,196,183,188,185,188,193,193,183,188,185,180,198,190,185,190,183,185,190,185,188,198,196,180,185,190) > par3 = '20' > par2 = '0.95' > par1 = 'two.sided' > par3 <- '20' > par2 <- '0.95' > par1 <- 'two.sided' > #'GNU S' R Code compiled by R2WASP v. 1.2.327 () > #Author: root > #To cite this work: Wessa P., 2013, One Sample Tests about the Mean (v1.0.3) in Free Statistics Software (v$_version), Office for Research Development and Education, URL http://www.wessa.net/rwasp_onesampletests_mean.wasp/ > #Source of accompanying publication: > # > par2 <- as.numeric(par2) > par3 <- as.numeric(par3) > (tt <- t.test(x,mu=par3,alternative=par1,conf.level=par2)) One Sample t-test data: x t = 169.8033, df = 49, p-value < 2.2e-16 alternative hypothesis: true mean is not equal to 20 95 percent confidence interval: 186.1896 190.1704 sample estimates: mean of x 188.18 > > #Note: the /var/wessaorg/rcomp/createtable file can be downloaded at http://www.wessa.net/cretab > load(file="/var/wessaorg/rcomp/createtable") > > a<-table.start() > a<-table.row.start(a) > a<-table.element(a,'One Sample t-test',2,TRUE) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'H0',header=TRUE) > a<-table.element(a,tt$null.value) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Alternative',header=TRUE) > a<-table.element(a,tt$alternative) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'CI',header=TRUE) > a<-table.element(a,par2) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'Sample Mean',header=TRUE) > a<-table.element(a,mean(x)) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'T-Test',header=TRUE) > a<-table.element(a,tt$statistic) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'DF',header=TRUE) > a<-table.element(a,tt$parameter) > a<-table.row.end(a) > a<-table.row.start(a) > a<-table.element(a,'P-Value',header=TRUE) > a<-table.element(a,tt$p.value) > a<-table.row.end(a) > a<-table.end(a) > table.save(a,file="/var/wessaorg/rcomp/tmp/143ib1386413410.tab") > > > > proc.time() user system elapsed 0.500 0.134 0.601