title: Statsmodels API OLS regression: ValueError -> shapes (95, 3) and (4,) are not aligned
body: <pre><code>def fit_linear_regression(X, y):
      X = sm.add_constant(X)
      est = sm.OLS(y, X)
      est = est.fit()
      return est
  
  print(X_train.shape) // outputs (604, 41)
  print(X_test.shape) // outputs (95, 41)
  
  model = fit_linear_regression(X_train.iloc[:, [0, 1, 2]], y_train)
  
  model.predict(X_test.iloc[:, [0, 1, 2]])
  </code></pre>
  <p>When I run this script, I get the following error</p>
  <p><code>ValueError: shapes (95,3) and (4,) not aligned: 3 (dim 1) != 4 (dim 0)</code></p>
  <p>When I do not select any columns but just include the whole dataframes, it does the same with <code>shapes(95, 41) and (42,)</code> not aligned. What the hell is going on here?</p>
  <p>X_train, y_train and y_test are panda dataframes.</p>