title: Plotting a histogram with ggplot2 when the magnitude of data is large
body: <p>I have this following data frame, <code>df</code> for which I desire to plot a histogram.</p>
  
  <pre><code>     x
  1   -28313937
  2   -218616099
  3   -18406124
  4   20307666
  5   31985283
  6   41429217
  7   46488567
  8   47690792
  9   51127321
  10  53168291
  11  55247883
  12  -49200409
  13  33398814
  14  36198419
  15  42765257
  16  45857195
  17  43870899
  18  50557988
  19  49574516
  20  52317786
  21  50769743
  </code></pre>
  
  <p>I use the following piece of code for plotting the histogram,</p>
  
  <pre><code>R_hist &lt;- ggplot(df, aes(x=x)) + 
  geom_histogram(binwidth=.5, colour="black", fill="white") + 
  geom_vline(aes(xintercept=mean(x, na.rm=T)), color="violet", linetype="dashed", size=1)
  </code></pre>
  
  <p>When I tried to call the object R_hist, I get an <strong>Error : cannot allocate vector of size 4.1 Gb
  In addition: Warning messages: 
  1: In seq.default(round_any(range[1], size, floor), round_any(range[2],  :
    Reached total allocation of 4021Mb: see help(memory.size)</strong>    </p>
  
  <p>Could someone please let me know why the histogram is not being plotted as it should here</p>
  
  <p>Thanks.</p>