title: ValueError: could not broadcast input array from shape (26000,1) into shape (26000) for sklearn preprocessing StandardScaler
body: <p>I am working on a <code>numpy array X</code> that has multiple features (or columns).</p>
  <p>I am trying to standardize the first feature (column) of the dataset:</p>
  <pre><code>from sklearn.preprocessing import StandardScaler
  sc = StandardScaler()
  
  X[:,0] = sc.fit_transform(X[:,0].reshape(-1,1))
  </code></pre>
  <p>and I get this error:</p>
  <pre><code>ValueError: could not broadcast input array from shape (26000,1) into shape (26000)
  </code></pre>
  <p>if I remove <code>reshape(-1,1)</code> then I get this error:</p>
  <pre><code>Reshape your data either using array.reshape(-1, 1) if your data has a single feature or array.reshape(1, -1) if it contains a single sample.
  </code></pre>
  <p>How can I tackle this problem?</p>
  <p>Thanks in advance!</p>