title: 'DataFrame' object has no attribute 'to_frame'
body: <p>I am new to python. Just following the tutorial: <a href="https://www.hackerearth.com/practice/machine-learning/machine-learning-projects/python-project/tutorial/" rel="nofollow noreferrer">https://www.hackerearth.com/practice/machine-learning/machine-learning-projects/python-project/tutorial/</a></p>
  
  <p>This is the dataframe miss:</p>
  
  <pre><code>miss = train.isnull().sum()/len(train)
  miss = miss[miss&gt;0]
  miss.sort_values(inplace = True)
  miss
  
  Electrical      0.000685
  MasVnrType      0.005479
  MasVnrArea      0.005479
  BsmtQual        0.025342
  BsmtCond        0.025342
  BsmtFinType1    0.025342
  BsmtExposure    0.026027
  BsmtFinType2    0.026027
  GarageCond      0.055479
  GarageQual      0.055479
  GarageFinish    0.055479
  GarageType      0.055479
  GarageYrBlt     0.055479
  LotFrontage     0.177397
  FireplaceQu     0.472603
  Fence           0.807534
  Alley           0.937671
  MiscFeature     0.963014
  PoolQC          0.995205
  dtype: float64
  </code></pre>
  
  <p>Now I just want to visualize those missing values"</p>
  
  <pre><code>#visualising missing values
  miss = miss.to_frame()
  miss.columns = ['count']
  miss.index.names = ['Name']
  miss['Name'] = miss.index
  </code></pre>
  
  <p>And this is the error I got:</p>
  
  <pre><code>AttributeError                            Traceback (most recent call last)
  &lt;ipython-input-42-cd3b25e8862a&gt; in &lt;module&gt;()
        1 #visualising missing values
  ----&gt; 2 miss = miss.to_frame()
  
      C:\Users\Username\AppData\Local\Continuum\Anaconda3\lib\site-packages\pandas\core\generic.py in __getattr__(self, name)
         2742             if name in self._info_axis:
         2743                 return self[name]
      -&gt; 2744             return object.__getattribute__(self, name)
         2745 
         2746     def __setattr__(self, name, value):
  
      AttributeError: 'DataFrame' object has no attribute 'to_frame'
  </code></pre>
  
  <p>What am I missing here? </p>