title: panda filtering on date range
body: <p>I have been researching this and have not been able to figure it out, so I need some guidance.</p>
  <p>I am importing a csv and I'd like to filter it on multiple date. I convert the timestamp to a datetime and then parse out the date into its own column.</p>
  <p>My dataframe</p>
  <pre><code>    open    high    low     close   volume  timestamp   datetime    date
  5850    148.5700    148.83  148.535     148.6800    1054078     1629120600000   2021-08-16 13:30:00     2021-08-16
  5851    148.7200    149.15  148.700     149.1400    536106  1629120660000   2021-08-16 13:31:00     2021-08-16
  5852    149.1399    149.30  149.130     149.1700    420194  1629120720000   2021-08-16 13:32:00     2021-08-16
  5853    149.1630    149.25  149.120     149.2200    344097  1629120780000   2021-08-16 13:33:00     2021-08-16
  5854    149.2150    149.56  149.140     149.5600    629713  1629120840000   2021-08-16 13:34:00     2021-08-16
  ...     ...     ...     ...     ...     ...     ...     ...     ...
  3895    162.6950    162.72  162.550     162.6300    300778  1659124500000   2022-07-29 19:55:00     2022-07-29
  3896    162.6200    162.64  162.515     162.5499    260475  1659124560000   2022-07-29 19:56:00     2022-07-29
  3897    162.5500    162.62  162.500     162.5699    314390  1659124620000   2022-07-29 19:57:00     2022-07-29
  3898    162.5600    162.60  162.500     162.5250    471114  1659124680000   2022-07-29 19:58:00     2022-07-29
  3899    162.5300    162.64  162.410     162.5700    1114601     1659124740000   2022-07-29 19:59:00     2022-07-29
  </code></pre>
  <p>and its info</p>
  <pre><code>&lt;class 'pandas.core.frame.DataFrame'&gt;
  Int64Index: 96385 entries, 5850 to 3899
  Data columns (total 8 columns):
   #   Column     Non-Null Count  Dtype         
  ---  ------     --------------  -----         
   0   open       96385 non-null  float64       
   1   high       96385 non-null  float64       
   2   low        96385 non-null  float64       
   3   close      96385 non-null  float64       
   4   volume     96385 non-null  int64         
   5   timestamp  96385 non-null  int64         
   6   datetime   96385 non-null  datetime64[ns]
   7   date       96385 non-null  object        
  dtypes: datetime64[ns](1), float64(4), int64(2), object(1)
  memory usage: 6.6+ MB
  </code></pre>
  <p>I formulate the dates I want to filter</p>
  <pre><code>exp_fri = pd.date_range('2021-11-01','2022-07-31',freq='WOM-3FRI').strftime(&quot;%Y-%m-%d&quot;).tolist()
  </code></pre>
  <p>I have also tried the date range excluding the tolist fuction which is an dtype = datetime but given that the date column in my df is an object I believe I am doing a proper comparison.</p>
  <pre><code>exp_fri = pd.date_range('2021-11-01','2022-07-31',freq='WOM-3FRI').strftime(&quot;%Y-%m-%d&quot;)
  type(exp_fri)
  </code></pre>
  <p>I then try to filter using</p>
  <pre><code>df_expfri = df[df['date']].isin[exp_fri]
  df_expfri
  </code></pre>
  <p>but get key error 'date'</p>
  <pre><code>KeyError                                  Traceback (most recent call last)
  File C:\ProgramData\Anaconda3\lib\site-packages\pandas\core\indexes\base.py:3621, in Index.get_loc(self, key, method, tolerance)
     3620 try:
  -&gt; 3621     return self._engine.get_loc(casted_key)
     3622 except KeyError as err:
  
  File C:\ProgramData\Anaconda3\lib\site-packages\pandas\_libs\index.pyx:136, in pandas._libs.index.IndexEngine.get_loc()
  
  File C:\ProgramData\Anaconda3\lib\site-packages\pandas\_libs\index.pyx:163, in pandas._libs.index.IndexEngine.get_loc()
  
  File pandas\_libs\hashtable_class_helper.pxi:5198, in pandas._libs.hashtable.PyObjectHashTable.get_item()
  
  File pandas\_libs\hashtable_class_helper.pxi:5206, in pandas._libs.hashtable.PyObjectHashTable.get_item()
  
  KeyError: 'date'
  
      The above exception was the direct cause of the following exception:
      
      KeyError                                  Traceback (most recent call last)
      Input In [75], in &lt;cell line: 3&gt;()
            1 #https://datagy.io/filter-pandas/
            2 #east_west2 = df[df['Region'].isin(['West', 'East'])]
      ----&gt; 3 df_expfri = df[df['date']].isin[exp_fri]
            4 df_expfri
      
      File C:\ProgramData\Anaconda3\lib\site-packages\pandas\core\frame.py:3505, in DataFrame.__getitem__(self, key)
         3503 if self.columns.nlevels &gt; 1:
         3504     return self._getitem_multilevel(key)
      -&gt; 3505 indexer = self.columns.get_loc(key)
         3506 if is_integer(indexer):
         3507     indexer = [indexer]
      
      File C:\ProgramData\Anaconda3\lib\site-packages\pandas\core\indexes\base.py:3623, in Index.get_loc(self, key, method, tolerance)
         3621     return self._engine.get_loc(casted_key)
         3622 except KeyError as err:
      -&gt; 3623     raise KeyError(key) from err
         3624 except TypeError:
         3625     # If we have a listlike key, _check_indexing_error will raise
         3626     #  InvalidIndexError. Otherwise we fall through and re-raise
         3627     #  the TypeError.
         3628     self._check_indexing_error(key)
      
      KeyError: 'date'
  </code></pre>
  <p>What am I doing wrong?</p>