title: Dotplot: How to change dot sizes of dotplot based on a value in data and make all x axis values into whole numbers
body: <p>I have made a dotplot for my data but need to help with the finishing touches. Been around stackoverflow a bit and haven't seen any posts that directly answer my queries yet. </p>
  
  <p>My code for my dotplot is:</p>
  
  <pre><code>ggplot()+
  geom_dotplot(mapping = aes(x= reorder(Description, -p.adjust), y=Count, fill=-p.adjust),
               data = head(X[which(X$p.adjust &lt; 0.05),], n = 15), binaxis = 'y', dotsize = 2,
              method = 'dotdensity', binpositions = 'all', binwidth = NULL)+
    scale_fill_continuous(low="black", high="light grey") +
    labs(y = "Associated genes", x = "wikipathways", fill = "p.adjust") +
    theme(axis.text=element_text(size=8)) +
    ggtitle('') +
    theme(plot.title = element_text(2, face = "bold", hjust = 1),
          legend.key.size = unit(2, "line")) +
    theme(panel.background = element_rect(fill = 'white', colour = 'black'))+
    coord_fixed(ratio = 0.5)+
    coord_flip()
  </code></pre>
  
  <p>Let's say the X is something along the lines of:</p>
  
  <pre><code>   Description   p.adjust  Count   GeneRatio  
  1  DescriptionA  0.001     3       3/20
  2  DescriptionB  0.002     2       2/20
  3  DescriptionC  0.003     5       5/20
  4  DescriptionD  0.004     10      10/20
  </code></pre>
  
  <p>To complete this plot I need two edits.</p>
  
  <p>I would like to use base the size of the dots on the GeneRatio, and make a secondary key based around this size. Is this possible with ggplot2, dotplots? </p>
  
  <p>Next I would like to keep the X axis values as integers. I'd want to avoid using something like scale_x_continuous(limits = c(2, 10)) as this plot code is part of a function for multiple data sets of various sizes. Thus containing the limits/scale would not work well.  </p>
  
  <p>Help would be most appreciated.</p>