1. power.t<-function(m){ count.t<-0 for (i in 1:100){ x <- rnorm(25,5) y <- rnorm(25,5+m) if (t.test(x,y, alternative="l", var.equal=T)$p.value <.05) {count.t<-count.t+1} } return(count.t/100) } power.w<-function(m){ count.w<-0 for (i in 1:100){ x <- rnorm(25,5) y <- rnorm(25,5+m) if (wilcox.test(x,y,alternative="l")$p.value <.05) {count.w<-count.w+1} } return(count.w/100) } m<-seq(0,2,.25) d<-length(m) curve.t<-rep(0,d) curve.w<-rep(0,d) for (i in 1:d){ curve.t[i]<-power.t(m[i]) curve.w[i]<-power.w(m[i]) } plot(m, curve.t, type="l", lty=1) points(m, curve.w, type="l", lty=2) legend(1.5,0.2,c("t-test","Wilcoxon"),lty=c(1,2)) 2. The 20 animals were randomized to 2 treatments (10 per treatment), so we have two independent samples. Alternative is two-sided. (a) Assuming both underlying distributions are symmetric (which seems rather dubious here), you could use a 2-sample t-test to assess the differences between the population medians. Compare 2 SDs first. They are close. Then do the "standard" 2-sample t-test (assuming common population variances). It yields a two-sided p-value of 0.006. (b) Use of wilcox.test leads to a p-value of 0.02. (c) The sample size is not very large. So, t-test would do better if the distributions are normal. However, there is not enough evidence to claim normality (look at 2 qqplots for 2 treatments). So, probably prefer the Wilcoxon in this situation.