title: pandas set index using split of column as new index
body: <p>I have a dataframe that I get from a third party:</p>
  
  <pre><code>r = get_finance_rate([eq_opt_px.index[0],vol_opt_px.index[0]], expiry)
  </code></pre>
  
  <p>r:</p>
  
  <pre><code>    ticker                          field           value
  0   SPX US 08/17/2018 C2830.0 Index OPT_FINANCE_RT  2.004648
  1   VXX US 08/17/2018 C27.0 Index   OPT_FINANCE_RT  2.03248
  </code></pre>
  
  <p>Since the output is returned in a format that does not fits my needs I would like to reset the index. The obvious solution for what I'm trying to do is</p>
  
  <pre><code>r['aux id'] = [x.split()[0] for x in r['ticker']]
  r = r.set_index('aux id')
  </code></pre>
  
  <p>Result:</p>
  
  <pre><code>    ticker                          field           value
  SPX SPX US 08/17/2018 C2830.0 Index OPT_FINANCE_RT  2.004648
  VXX VXX US 08/17/2018 C27.0 Index   OPT_FINANCE_RT  2.03248
  </code></pre>
  
  <p>However I would like to do something like</p>
  
  <pre><code>r = get_finance_rate([eq_opt_px.index[0],vol_opt_px.index[0]], expiry).set_index('ticker'.split(' ')[0])
  </code></pre>
  
  <p>The previous instruction does not perform the split</p>
  
  <pre><code>ticker                          field           value
  SPX US 08/17/2018 C2830.0 Index OPT_FINANCE_RT  2.004648
  VXX US 08/17/2018 C27.0 Index   OPT_FINANCE_RT  2.03248
  </code></pre>
  
  <p>Is there such a way to accomplish what I want without having to create the temporary column?</p>