title: Set frequency in xts object
body: <p>I want to create an <code>xts</code> object in R, which I then want to decompose to seasonal and trend.</p>
  
  <pre><code>&gt; require(xts)
  &gt; require(lubridate) 
  &gt; chicos$date &lt;- ymd(chicos$date)
  &gt; ctr.ts &lt;- xts(chicos[, 7], order.by = chicos[, 8], frequency = 365)
  &gt; plot(ctr.ts, main="Meaningful title")
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/Dxvch.png" alt="enter image description here"></p>
  
  <p>When I try to decompose it, I get this error message..</p>
  
  <pre><code>&gt; plot(decompose(ctr.ts))
  Error in decompose(ctr.ts) : time series has no or less than 2 periods
  </code></pre>
  
  <p>My observations are daily, and span from 2014-12-01 to 2015-02-25. Did I set the wrong <code>frequency</code>? </p>