title: Error while plotting monthly time series in ggplot
body: <p>I'm trying to create a monthly time series in ggplot for time series analysis. This is my data:</p>
  <pre>
  rdata1 &lt;- read_table2(&quot;date  sales_revenue_incl_credit 
                                      2017-07 56,037.46
                                      2017-08 38333.9
                                      2017-09 48716.92
                                      2017-10 65447.67
                                      2017-11 134752.57
                                      2017-12 116477.39
                                      2018-01 78167.25
                                      2018-02 75991.44
                                      2018-03 42520.93
                                      2018-04 70489.92
                                      2018-05 121063.35
                                      2018-06 76308.47
                                      2018-07 118085.7
                                      2018-08 96153.38
                                      2018-09 82827.1
                                      2018-10 109288.83
                                      2018-11 145774.52
                                      2018-12 141572.77
                                      2019-01 123055.83
                                      2019-02 104232.24
                                      2019-03 435086.33
                                      2019-04 74304.96
                                      2019-05 117237.82
                                      2019-06 82013.47
                                      2019-07 99382.67
                                      2019-08 138455.2
                                      2019-09 97301.99
                                      2019-10 137206.09
                                      2019-11 109862.44
                                      2019-12 118150.96
                                      2020-01 140717.9
                                      2020-02 127622.3
                                      2020-03 134126.09&quot;)
  </pre>
  <p>I now use the below code to change the class of date and then plot with breaks and labels much easier using date_labels and date_breaks.</p>
  <pre>rdata1 %&gt;%
    mutate(date = ymd(date)) %&gt;%
    ggplot(aes(date, sales_revenue_incl_credit)) +
    geom_line() +
    scale_x_date(date_labels = &quot;%b %Y&quot;, date_breaks = &quot;1 month&quot;)+
    theme_bw()+
    theme(axis.text.x = element_text(angle = 90, vjust=0.5), 
          panel.grid.minor = element_blank())
  
  </pre>
  <p>I get the following error:</p>
  <blockquote>
  <p>Error in seq.int(r1$mon, 12 * (to0$year - r1$year) + to0$mon, by) :
  'from' must be a finite number</p>
  </blockquote>