title: Sklearn PLSRegression predict fails with binary indicator column in X matrix
body: <p>I'm currently using PLS Regression to predict a 3 column matrix and using the default n_components of 2. I get a value error due to incorrect matrix dimensions when calling the predict function. This only occurs when there is a binary variable column in the X matrix.</p>
  <h3>Reproducible Example 1: Binary independent variable results in predict error</h3>
  <pre><code>import numpy as np
  from sklearn.cross_decomposition import PLSRegression
  
  # Create x and y matrix
  X_test = np.reshape(np.random.randn(30),(10, 3))
  y_test = np.reshape(np.random.randn(30), (10,3))
  
  # Create binary column
  t = np.ndarray((10,1))
  t[:5,:] = 0
  t[5:10,:] = 1
  X_test = np.hstack([X_test, t])
  
  # Estimate PLS Regression
  pls_reg = PLSRegression(n_components = 2)
  pls_reg.fit(y_test, X_test)
  pls_reg.predict(X_test)
  </code></pre>
  <p>This results in the following sklearn error:</p>
  <pre><code>ValueError                                Traceback (most recent call last)
  /tmp/ipykernel_31713/1419766927.py in &lt;module&gt;
       13 pls_reg = PLSRegression(n_components = 2)
       14 pls_reg.fit(y_test, X_test)
  ---&gt; 15 pls_reg.predict(X_test)
  
  ~/Documents/esgpls_scoring/lib64/python3.7/site-packages/sklearn/cross_decomposition/_pls.py in predict(self, X, copy)
      382         X = check_array(X, copy=copy, dtype=FLOAT_DTYPES)
      383         # Normalize
  --&gt; 384         X -= self._x_mean
      385         X /= self._x_std
      386         Ypred = np.dot(X, self.coef_)
  
  ValueError: operands could not be broadcast together with shapes (10,4) (3,) (10,4) 
  </code></pre>
  <h3>Reproducible Example 2: Same X matrix removing binary column results in no error</h3>
  <pre><code># Using same y_test and X_test previously generated
  pls_reg = PLSRegression(n_components = 2)
  pls_reg.fit(y_test, X_test[:,:3])
  pls_reg.predict(X_test[:,:3])
  </code></pre>
  <h3>Summary</h3>
  <p>Is this an issue with the PLSRegression predict function? Is there a theoretical reason why you shouldn't be using a X matrix with this form? It isn't clear from the error thrown.</p>
  <p>I'm running this on sklearn version 0.24.1</p>