title: Convert a string to dataframe
body: <p>I have a string like this:</p>
  
  <pre><code>txt = 'A      AGILENT TECH INC              \nAA     ALCOA INC                     '
  </code></pre>
  
  <p>And want to obtain a <code>DataFrame</code> like this:</p>
  
  <pre><code>In [185]: pd.DataFrame({'col1':['A','AA'],'col2':['AGILENT TECH INC','ALCOA INC']})
  Out[185]:
    col1              col2
  0    A  AGILENT TECH INC
  1   AA         ALCOA INC
  </code></pre>
  
  <p>I tried so far:</p>
  
  <pre><code>from StringIO import StringIO
  import re
  
  pd.DataFrame.from_csv(StringIO(re.sub(' +\n', ';', txt)), sep=';')
  
  Out[204]:
  Empty DataFrame
  Columns: [AA     ALCOA INC                     ]
  Index: []
  </code></pre>
  
  <p>But the result is not the one expected.  It seems I do not handle all optionality of <code>from_csv</code> or <code>StringIO</code>.</p>
  
  <p>It is certainly linked to this <a href="https://stackoverflow.com/questions/22604564/how-to-create-a-pandas-dataframe-from-string">question</a>.</p>