R version 2.15.2 (2012-10-26) -- "Trick or Treat" Copyright (C) 2012 The R Foundation for Statistical Computing ISBN 3-900051-07-0 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(21,15,18,NA,8,19,NA,20,16,14,NA,NA,14,8,23,NA,9,NA,NA,15,NA,19,6,NA,11,17,17,5,NA,15,NA,17,20,NA,NA,NA,7,NA,NA,15,15,10,14,NA,NA,9,NA,NA,18,NA,17,14,16,10,NA,10,14,10,NA,NA,9,12,16,NA,18,NA,NA,NA,18,9,19,NA,NA,23,22,14,14,NA,NA,NA,NA,12,NA,12,NA,NA,16,11,14,13,9,NA,13,19,13,13,NA,14,NA,NA,11,NA,18,19,NA,15,NA,19,15,17,8,10,12,12,20,NA,12,14,NA,10,18,18,7,18,9,NA,22,11,NA,NA,15,NA,NA,NA,NA,14,14,NA,NA,20,8,17,9,NA,22,10,NA,NA,NA,NA,12,12,20,NA,NA,NA,18,16,13,17,NA,17) > par3 = '15' > par2 = '0.95' > par1 = 'greater' > par3 <- '15' > par2 <- '0.95' > par1 <- 'greater' > #'GNU S' R Code compiled by R2WASP v. 1.0.44 () > #Author: Dr. Ian E. Holliday > #To cite this work: Ian E. Holliday, 2009, YOUR SOFTWARE TITLE (vNUMBER) in Free Statistics Software (v$_version), Office for Research Development and Education, URL http://www.wessa.net/rwasp_YOURPAGE.wasp/ > #Source of accompanying publication: > #Technical description: > 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 = -1.4913, df = 97, p-value = 0.9304 alternative hypothesis: true mean is greater than 15 95 percent confidence interval: 13.66283 Inf sample estimates: mean of x 14.36735 > > #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/1l1dn1355173617.tab") > > > > proc.time() user system elapsed 0.274 0.064 0.313