# Two sample t test. Example is androsterone levels in # heterosexual (s) and homosexual (g) males, from # Margolese, MS 1970. Homosexuality: a new endocrine # correlate. Hormones and Behavior 1:151-155. andro=read.table("androsterone.txt",header=TRUE) attach(andro) andro t.test(androsterone~orientation,mu=0,conf.level=.95) boxplot(androsterone~orientation,range=0, names=c("gay","straight"),ylab="androsterone",boxwex=.5) detach(andro)