title: Standardize some columns in Python Pandas dataframe?
body: <p>Python code below only return me an array, but I want the scaled data to replace the original data.</p>
  
  <pre><code>from sklearn.preprocessing import StandardScaler
  df = StandardScaler().fit_transform(df[['cost', 'sales']])
  df
  </code></pre>
  
  <p>output</p>
  
  <pre><code>array([[ 1.99987622, -0.55900276],
         [-0.49786658, -0.45658181],
         [-0.5146864 , -0.505097  ],
         [-0.48104676, -0.47814412],
         [-0.50627649,  1.9988257 ]])
  </code></pre>
  
  <p>original data</p>
  
  <pre><code>id  cost    sales   item
  1   300       50    pen
  2   3         88    bottle
  3   1         70    drink
  4   5         80    cup
  5   2        999    ink
  </code></pre>