title: Errorbars on bar-graph
body: <p>I'm trying to get: a nice bar graph of groups. I'd like error bars on each bar like this (or similar at your discretion):</p>
  
  <p><img src="https://i.stack.imgur.com/fbgop.png" alt="enter image description here"></p>
  
  <p>I have the means: </p>
  
  <pre><code>ff =
               Medical eq    Patient   Hygiene   Near bed   Far bed
  Direct        1.2759    0.9253    0.6092    1.0460    1.3276
  Housekeeping  1.0833    0.2500    0.5833    2.1667    1.3333
  Mealtimes      0        0.3000    0.7000    1.4500    0.5000
  Medication    0.3694    0.7838    0.8919    1.5495    1.0541
  Misc          0.1059    0.1294    0.4118    0.8000    0.8353
  Personal      0.0370    0.4074    0.8148    1.2593    0.7037
  </code></pre>
  
  <p>the standard deviations</p>
  
  <p>ee =</p>
  
  <pre><code>2.0411    1.1226    0.8378    1.5007    1.3776
  1.3114    0.4523    0.6686    2.4058    1.1547
       0    0.7327    1.3803    2.1392    0.6070
  0.7499    0.9186    1.0300    1.2844    1.3062
  0.4371    0.3712    0.7605    1.0212    0.6699
  0.1925    0.6939    1.6417    3.5582    1.5644
  </code></pre>
  
  <p>instead I get this:</p>
  
  <p><img src="https://i.stack.imgur.com/YBd4N.png" alt="enter image description here"></p>
  
  <p>by using:</p>
  
  <pre><code>bb=bar(ff'); hold all
  data=repmat([1:6]'*ones(5,1)',1,1)
  er=errorbar(data, ff, ee, '.')
  </code></pre>
  
  <p>I read I have to find the centre of each bar? That's crazy! Any workaround?</p>