x <- c(53.67,54.00,54.00,54.33,54.33,54.67,54.67,54.67,55.00,55.00,55.33,55.33,55.33,55.67,55.67,56.00,56.00,56.00,56.33,56.33,56.67,56.67,56.67,56.67,57.00,57.33,57.33,57.67,57.67,58.00,58.00,58.00,58.00,58.00,58.00,58.00,58.00,58.33,58.33,58.67,58.67,58.67,58.67,58.67,58.67,58.67,59.00,59.00,59.33,59.33,59.33,59.33,59.33,59.67,59.67,59.67,59.67,59.67,59.67,60.00,60.00,60.00,60.00,60.00,60.00,60.00,60.00,60.00,60.33,60.33,60.33,60.33,60.33,60.33,60.67,60.67,60.67,60.67,60.67,61.00,61.00,61.00,61.00,61.00,61.00,61.33,61.33,61.33,61.33,61.33,61.33,61.33,61.67,61.67,61.67,61.67,61.67,61.67,61.67,61.67,62.00,62.00,62.00,62.00,62.00,62.00,62.33,62.33,62.33,62.33,62.67,63.00,63.00,63.00,63.33,63.33,63.33,63.33,63.33,63.67,63.67,63.67,63.67,63.67,63.67,63.67,63.67,63.67,64.00,64.00,64.00,64.00,64.00,64.00,64.00,64.00,64.33,64.33,64.67,64.67,64.67,64.67,65.00,65.00,65.00,65.33,65.33,65.67,65.67,65.67,65.67)
par1 = '20'
ylab = 'Y avriable Name'
xlab = 'X variable Name'
postscript(file="/var/wessaorg/rcomp/tmp/1oljd1318948540.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) 
par1 <- as.numeric(par1)
myhist<-hist(x, breaks=par1, col=2)
dev.off()
postscript(file="/var/wessaorg/rcomp/tmp/2yr5z1318948540.ps",horizontal=F,onefile=F,pagecentre=F,paper="special",width=8.3333333333333,height=5.5555555555556) 
qqnorm(x)
qqline(x, col=2, xlab=xlab, ylab=ylab)
dev.off()

#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,'Descriptive Statistics',3,TRUE)
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'mean',header=TRUE)
a<-table.element(a,mean(x))
a<-table.element(a,hyperlink('http://www.xycoon.com/arithmetic_mean.htm','formula','click to see the formula'))
a<-table.row.end(a)
a<-table.row.start(a)
a<-table.element(a,'standard deviation',header=TRUE)
a<-table.element(a,sd(x))
a<-table.element(a,hyperlink('http://www.xycoon.com/unbiased1.htm','formula','click to see the formula'))
a<-table.row.end(a)
a<-table.end(a)
table.save(a,file="/var/wessaorg/rcomp/tmp/30i0w1318948540.tab") 

try(system("convert tmp/1oljd1318948540.ps tmp/1oljd1318948540.png",intern=TRUE))
try(system("convert tmp/2yr5z1318948540.ps tmp/2yr5z1318948540.png",intern=TRUE))

