data(aHDL)
y<-t(matrix(aHDL$hdl,4,406))
y<-y[,c(1,3,2,4)]
colnames(y)<-c("D","N","R","B")
# 6 pairwise comparisons of 4 groups
o<-matrix(NA,dim(y)[1],6)
colnames(o)<-1:6
k<-0
for (i in 1:3)
for (j in (i+1):4){
k<-k+1
colnames(o)[k]<-paste(colnames(y)[i],colnames(y)[j],sep="-")
o[,k]<-y[,i]-y[,j]
}
rm(i,j,k)
# Plotting tick marks. Remember, the transformation compresses
# extremes, so unequally spaced tick marks are usually needed.
tcks<-c(-100,-60,-40,-20,0,20,40,60,200)
# tails transformed by the p=-1 power (i.e., reciprocal)
boxplotTT(o,p=-1,qu=.95,tcks=tcks,ylab="HDL",
xlab="Pairwise Comparisons of 4 Groups",
main="HDL Differences in 4 Alcohol Groups")
Run the code above in your browser using DataLab