title: ggplot2: Is there a fix for jagged, poor-quality text produced by geom_text()?
body: <p>While adding annotation text to a plot I noticed that <code>geom_text()</code> produced unsightly, jagged text, while <code>annotate()</code> produced smooth, nice-looking text. Does anyone know why this happens and if there's any way to fix it? I know I could just use <code>annotate()</code> here, but there are probably cases where <code>geom_text()</code> is preferable, and I'd like to find a fix. Also, <code>geom_text()</code> can't be <em>intended</em> to give poor-looking text, so either I'm doing something wrong, or I've run into some sort of subtle side effect. </p>
  
  <p>Here's some fake data and the code to produce the graph, plus an image showing the results. </p>
  
  <pre><code>library(ggplot2)
  age = structure(list(age = c(41L, 40L, 43L, 44L, 40L, 42L, 44L, 45L, 
          44L, 41L, 43L, 40L, 43L, 43L, 40L, 42L, 43L, 44L, 43L, 41L)), 
          .Names = "age", row.names = c(NA, -20L), class = "data.frame")
  ggplot(age, aes(age)) + 
    geom_histogram() +
    scale_x_continuous(breaks=seq(40,45,1)) +
    stat_bin(binwidth=1, color="black", fill="blue") +
    geom_text(aes(41, 5.2, 
              label=paste("Average = ", round(mean(age),1))), size=12) +
    annotate("text", x=41, y=4.5, 
             label=paste("Average = ", round(mean(age$age),1)), size=12)
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/u6Vqc.png" alt="enter image description here"></p>