title: Python PANDAS-Substring First INT or FLOAT Before Symbol
body: <p>I have a string column in a PANDAS dataframe I would like substring to create a new column.  The general format for the column is this:</p>
  
  <pre><code>"THING 10MG/OTHER THING 100MG"
  "THING 10MG"
  "THING 10.5MG"
  "THING 10.5MCG"
  </code></pre>
  
  <p>What I need is a regex or other pattern matching technique to extract these results:</p>
  
  <pre><code>"10"
  "10"
  "10.5"
  "10.5"
  </code></pre>
  
  <p>The result is the first occurrence (from the left) of a float or int before MG or MCG.</p>
  
  <p>What I have so far produces incomplete results obviously:</p>
  
  <pre><code>df['string_field'].str.extract('(\d+)MG')
  </code></pre>
  
  <p>Any performant approach or tips would be appreciated.  Thanks.</p>