title: How can I reformat date from day-month-year to year-month-day?
body: <p>My goal is to remove the index and change the date format. Here is the data frame:            </p>
  
  <pre><code>       Date    tsla    goog    aapl   msft
  0    30-Dec-16  217.50  782.78  117.20  62.99
  1    29-Dec-16  219.20  785.93  117.11  63.20
  2    28-Dec-16  223.80  794.23  118.02  63.40
  3    27-Dec-16  222.25  797.86  117.80  64.07
  4    23-Dec-16  213.45  792.74  116.52  63.54
  5    22-Dec-16  209.99  793.32  116.51  64.10
  6    21-Dec-16  212.23  796.68  117.40  63.70
  7    20-Dec-16  209.00  798.65  117.50  63.80
  </code></pre>
  
  <p>Here is how I want it to look:</p>
  
  <pre><code>        Date    tsla    goog    aapl   msft
     2016-12-30  217.50  782.78  117.20  62.99
     2016-12-29  219.20  785.93  117.11  63.20
     2016-12-28  223.80  794.23  118.02  63.40
     2016-12-27  222.25  797.86  117.80  64.07
     2016-12-23  213.45  792.74  116.52  63.54
     2016-12-22  209.99  793.32  116.51  64.10
     2016-12-21  212.23  796.68  117.40  63.70
     2016-12-20  209.00  798.65  117.50  63.80
  </code></pre>
  
  <p>I tried what I found here <a href="https://stackoverflow.com/questions/32258915/reformatting-a-list-of-date-strings-to-day-month-year-in-python">Reformatting a list of date strings to day, month, year in Python</a>:</p>
  
  <pre><code>dfTSLA = [datetime.datetime.strptime(str(i), '%d-%m-%y').strftime('%y-%m-%d') for i in dfTSLA]
  </code></pre>
  
  <p>But i get the error "time data '\ufeffDate' does not match format '%d-%m-%y'", which makes sense I guess. Not sure how to go about it because the month is a string</p>