\begin{Schunk}
\begin{Sinput}
 x.null <- seq(-4, 4, .1)
 dx.null <- dnorm(x.null, m = 0, s = 1)
 plot(x.null, dx.null, type = "l", lwd = 2, xlim = c(-4, 8), yaxt = "n",
  xlab = "Effect Size (e.g., Mean-Difference between Groups)", ylab = "")
 ## If abs(z) > 1.96, reject the null at alpha = .05
 abline(v = qnorm(c(.025, .975)), lwd = 2, lty = "dashed")
 ## Type I errors occur for observations drawn outside the dashed lines
 x.8 <- x.null + 0.80
 dx.8 <- dnorm(x.8, m = 0.80)
 lines(x.8, dx.8, lwd = 2, col = "red")
\end{Sinput}
\end{Schunk}
