title: Can't drop a Date column KeyError: "['Date'] not found in axis
body: <p>I have a dataframe that has date, sales, and budget as column names. I want to drop the date column but it gives me an error <code>KeyError: &quot;['Date'] not found in axis&quot; </code></p>
  <p>Below is my code:</p>
  <pre><code>df2 = df.copy()   # make a copy of the dataframe object
  df2.drop(columns = ['Date'], inplace=True)   # drop the Date columns
  </code></pre>
  <p>The Datatype of all columns</p>
  <pre><code>Date                           datetime64[ns]
  Sales                                 float64
  Budget                                float64
  PPV                                   float64
  SOPPV                                 float64
  dtype: object
  </code></pre>
  <p>The full Trackback:</p>
  <pre><code>KeyError                                  Traceback (most recent call last)
  &lt;ipython-input-81-22d4dafeb1cb&gt; in &lt;module&gt;
  ----&gt; 1 df2 = df.drop(columns = ['Date'], inplace=True)
  
  ~/opt/anaconda3/lib/python3.7/site-packages/pandas/core/frame.py in drop(self, labels, axis, index, columns, level, inplace, errors)
     3995             level=level,
     3996             inplace=inplace,
  -&gt; 3997             errors=errors,
     3998         )
     3999 
  
  ~/opt/anaconda3/lib/python3.7/site-packages/pandas/core/generic.py in drop(self, labels, axis, index, columns, level, inplace, errors)
     3934         for axis, labels in axes.items():
     3935             if labels is not None:
  -&gt; 3936                 obj = obj._drop_axis(labels, axis, level=level, errors=errors)
     3937 
     3938         if inplace:
  
  ~/opt/anaconda3/lib/python3.7/site-packages/pandas/core/generic.py in _drop_axis(self, labels, axis, level, errors)
     3968                 new_axis = axis.drop(labels, level=level, errors=errors)
     3969             else:
  -&gt; 3970                 new_axis = axis.drop(labels, errors=errors)
     3971             result = self.reindex(**{axis_name: new_axis})
     3972 
  
  ~/opt/anaconda3/lib/python3.7/site-packages/pandas/core/indexes/base.py in drop(self, labels, errors)
     5016         if mask.any():
     5017             if errors != &quot;ignore&quot;:
  -&gt; 5018                 raise KeyError(f&quot;{labels[mask]} not found in axis&quot;)
     5019             indexer = indexer[~mask]
     5020         return self.delete(indexer)
  
  KeyError: &quot;['Date'] not found in axis&quot;
  </code></pre>