title: ddply + summarize for repeating same statistical function across large number of columns
body: <p>Ok, second R question in quick succession.</p>
  
  <p>My data:</p>
  
  <pre><code>           Timestamp    St_01  St_02 ...
  1 2008-02-08 00:00:00  26.020 25.840 ...
  2 2008-02-08 00:10:00  25.985 25.790 ...
  3 2008-02-08 00:20:00  25.930 25.765 ...
  4 2008-02-08 00:30:00  25.925 25.730 ...
  5 2008-02-08 00:40:00  25.975 25.695 ...
  ...
  </code></pre>
  
  <p>Basically normally I would use a combination of <code>ddply</code> and <code>summarize</code> to calculate ensembles (e.g. mean for every hour across the whole year). </p>
  
  <p>In the case above, I would  create a category, e.g. hour (e.g. <code>strptime(data$Timestamp,"%H") -&gt; data$hour</code> and then use that category in <code>ddply</code>, like <code>ddply(data,"hour", summarize, St_01=mean(St_01), St_02=mean(St_02)...)</code> to average by category across each of the columns. </p>
  
  <p>but here is where it gets sticky. I have more than 40 columns to deal with and I'm not prepared to type them all one by one as parameters to the <code>summarize</code> function. I used to write a loop in shell to generate this code but that's not how programmers solve problems is it?</p>
  
  <p>So pray tell, does anyone have a better way of achieving the same result but with less keystrokes?</p>