title: Adding StandardScaler() of values as new column to DataFrame returns partly NaNs
body: <p>I have a pandas DataFrame:</p>
  <pre><code>df['total_price'].describe()
  </code></pre>
  <p>returns</p>
  <pre><code>count    24895.000000
  mean       216.377369
  std        161.246931
  min          0.000000
  25%        109.900000
  50%        174.000000
  75%        273.000000
  max       1355.900000
  Name: total_price, dtype: float64
  </code></pre>
  <p>When I apply <code>preprocessing.StandardScaler()</code> to it:</p>
  <pre><code>x = df[['total_price']]
  standard_scaler = preprocessing.StandardScaler()
  x_scaled = standard_scaler.fit_transform(x)
  df['new_col'] = pd.DataFrame(x_scaled)   
  </code></pre>
  <p>&lt;y new column with the standardized values contains some <code>NaN</code>s:</p>
  <pre><code>df[['total_price', 'new_col']].head()
  
      total_price new_col
  0   241.95      0.158596
  1   241.95      0.158596
  2   241.95      0.158596
  3   81.95      -0.833691
  4   81.95      -0.833691
  
  df[['total_price', 'new_col']].tail()
  
          total_price new_col
  28167   264.0       NaN
  28168   264.0       NaN
  28176   94.0        NaN
  28177   166.0       NaN
  28178   166.0       NaN
  </code></pre>
  <p>What's going wrong here?</p>