title: Change day of the month in a Date to first day (01)
body: <p>I want to set the day of month in a <code>Date</code> to start date of current month (<code>01</code>).
  Now I use the following:</p>
  
  <pre><code>currentDate &lt;- Sys.Date()  #for getting current system date eg:2012-11-06
  formatDate &lt;- format(currentDate, "%Y-%m")  #it return 2012-11
  startDate &lt;- as.Date(paste(formatDate, "-01", sep = ""))
  # 2012-11-01 
  </code></pre>
  
  <p>Is there any easy way to do this?</p>