title: How to extract Data by date in python Pandas
body: <p>I am trying to extract data by certain dates (for example 06/20/2021 - 06/30/2021). Right now it reads the CSV file, sorts the data by date, and finds any duplicates. The next step is to extract all data by a date timeframe and am wondering how I can do this. Any help is very appreciated :). This is what I have below:</p>
  <pre><code>import pandas as pd
  from datetime import date, timedelta
  
  #df = pd.read_excel(r&quot;/Users/britevoxops2/Desktop/sample_date.xlsx&quot;) #reading Excel File
  
  df = pd.read_csv(r&quot;/Users/filename/Desktop/sample_date.csv&quot;)
  print(df) #print original data
  df.head()
  
  Final_result = df.sort_values('Joining Date') #sorting date
  print(Final_result)
  
  duplicate = df[df['Name'].duplicated() == True] #finding duplicate name
  print('Here are the Duplicates: \n',duplicate) 
  
  
   
  </code></pre>