I have a shared spreadsheet that gets rows added to it everyday. I am creating a script that reads the spreadsheet into a dataframe pd.read_excel(infile, sheet_name=0) and checks for duplicate rows using df.drop_duplicates(keep='first'). The script is going to be be an installed package on multiple people's computer for them to use at any time and different people will want to check different rows. Is there a way to have whoever wants to use the script choose the range of rows they want to check? For example, if the spreadsheet has 100 rows, and someone wants to check for duplicate rows in rows 40-60, is it possible to do this?
.iloc. For example,my_df = df.iloc[40:60,:]