title: Number of Observations in ggplot R
body: <p>I output each of boxplot of my response variable with respect to my categorical feautures but I cannot highlight number of observations of each category. I tried stat_summary and geom_text() options which are stated here but they are not working. </p>
  
  <p>How can I show them in my boxplots?</p>
  
  <p>Below is my code:</p>
  
  <pre><code>    for(i in 3:ncol(Train_factor)){
      b&lt;-paste("Boxplot for",colnames(Train_factor[i]))
      p10 &lt;- (ggplot(data=Train_factor, aes_string(x = names(Train_factor)[i], 
      y = "Response",fill=variable)) +
      geom_boxplot())
      plot_list[[i]] = p10
      }
      for (i in 3:ncol(Train_factor)) {
      file_name = paste("boxplot", i, ".tiff", sep="")
      tiff(file_name)
      print(plot_list[[i]])
      dev.off()
      }
  </code></pre>