title: Plotting errorbars in the logarithmic domain with negative values (Matlab)
body: <p>I have a vector, call it x, which contains very small numbers that I calculated from a mean.  I'd like to plot the logarithmic transform of x, say y=10*log10(x), along with errorbars equal to +- 2 standard deviations calculated when finding the mean.</p>
  
  <p>To do this, I'm using the following code:</p>
  
  <pre><code>figure
  errorbar(lengths, 10*log10(x), ...
      10*log10(x-2*std_x), 10*log10(x+2*std_x), 'o')
  </code></pre>
  
  <p>My problem is that since x contains such small values, x-2*std_x is usually a negative number, and you can't take the log of negative numbers.</p>
  
  <p>So I suppose my question is how can I plot errorbars in the logarithmic domain when subtracting the standard deviation in the linear domain gives me negative numbers?  I can't do the +- </p>