title: Split date into different columns for year, month and day
body: <p>I have zoo objects that look like:</p>
  
  <p>head(obs)</p>
  
  <pre><code>      Index pp
  1932-01-01  0
  1932-01-02  0.2
  1932-01-03  0
  </code></pre>
  
  <p>and I want to split the index into 3 columns (years, months and days in separate columns) so I can do some analyses per day of month using <code>ddply</code>.</p>
  
  <p>I don't know if it makes any difference but my dates were created using:</p>
  
  <pre><code>dates &lt;- as.Date(CET[,1], "%d-%m-%Y")
  obs &lt;- xts(CET[,2], dates)
  </code></pre>
  
  <p>where CET is the original file with dates in column 1 and pp in column 2.</p>
  
  <p>Thanks for helping!</p>