title: Converting string to date-time pandas
body: <p>I am fetching data from an API into a pandas dataframe whose index values are as follows:-</p>
  
  <pre><code>df.index=['Q1-2013',
   'Q1-2014',
   'Q1-2015',
   'Q1-2016',
   'Q1-2017',
   'Q1-2018',
   'Q2-2013',
   'Q2-2014',
   'Q2-2015',
   'Q2-2016',
   'Q2-2017',
   'Q2-2018',
   'Q3-2013',
   'Q3-2014',
   'Q3-2015',
   'Q3-2016',
   'Q3-2017',
   'Q3-2018',
   'Q4-2013',
   'Q4-2014',
   'Q4-2015',
   'Q4-2016',
   'Q4-2017',
   'Q4-2018']
  </code></pre>
  
  <p>It is a list of string values. Is there a way to convert this to pandas datetime?
  I explored few Q&amp;A and they are about using pd.to_datetime which works when the index is of object type.
  In this example, index values are strings.
  Expected output:</p>
  
  <pre><code>new_df=magic_function(df.index)
  print(new_df.index[0])
  01-2013
  </code></pre>
  
  <p>Wondering how to build "magic_function". Thanks in advance.
  Q1 is quarter1 which is January, Q2 is quarter2 which is April and Q3 is quarter3 which is July, Q4 is quarter4 which is October</p>