title: Python 3.6 AttributeError: module 'statsmodels' has no attribute 'compat'
body: <p>Totally new to Python. Saw no hits whatsoever on this error. Here's what I did, almost to the keystroke:</p>
  
  <ol>
  <li>Clean install of Python 3.6.</li>
  <li>pip install -U statsmodels</li>
  <li>pip install scipy</li>
  <li>pip install numpy</li>
  <li>pip install statsmodels --upgrade</li>
  <li>(In Python): import statsmodels.api as sm -> "AttributeError: module 'statsmodels' has no attribute 'compat'"</li>
  </ol>
  
  <p>Any suggestions? I'm just trying to walk through a multi regression tutorial on <a href="https://towardsdatascience.com/simple-and-multiple-linear-regression-in-python-c928425168f9" rel="noreferrer">https://towardsdatascience.com/simple-and-multiple-linear-regression-in-python-c928425168f9</a>. Full traceback follows.</p>
  
  <p>Thanks in advance.</p>
  
  <pre><code>&gt;&gt;&gt; import statsmodels.api as sm
  Traceback (most recent call last):
    File "&lt;stdin&gt;", line 1, in &lt;module&gt;
    File "C:\Users\dataylor\AppData\Local\Programs\Python\Python36-32\lib\site-packages\statsmodels\api.py", line 35, in &lt;module&gt;
      from .stats import api as stats
    File "C:\Users\dataylor\AppData\Local\Programs\Python\Python36-32\lib\site-packages\statsmodels\stats\api.py", line 65, in &lt;module&gt;
      from .mediation import Mediation
    File "C:\Users\dataylor\AppData\Local\Programs\Python\Python36-32\lib\site-packages\statsmodels\stats\mediation.py", line 22, in &lt;module&gt;
      import statsmodels.compat.pandas as pdc  # pragma: no cover
  AttributeError: module 'statsmodels' has no attribute 'compat'
  </code></pre>