title: Python: How to extract floating point numbers from a text file with mixed content?
body: <p>I have a tab delimited text file with the following data:</p>
  
  <pre><code>    ahi1
      b/se
  ahi 
  test    -2.435953
          1.218364
      ahi2
      b/se
  ahi 
  test    -2.001858
          1.303935
  </code></pre>
  
  <p>I want to extract the two floating point numbers to a separate csv file with two columns, ie. </p>
  
  <pre><code>-2.435953 1.218264
  
  -2.001858 1.303935
  </code></pre>
  
  <p>Currently my hack attempt is:</p>
  
  <pre><code> import csv
   from itertools import islice
   results = csv.reader(open('test', 'r'), delimiter="\n")
  
   list(islice(results,3))
   print results.next()
   print results.next()
   list(islice(results,3))
   print results.next()
   print results.next()
  </code></pre>
  
  <p>Which is not ideal.   I am a Noob to Python so I apologise in advance and thank you for your time.</p>