mercredi 14 juillet 2021

Select data from row that meets the condition below that row

I am looking how to create an if function that will select a row above another row where ColumnX is equal to the number 13.

I have this so far. if df.attrib.get("Column_Name") in ['13']:

I know this means that if column name "Column_Name" = 13 then ... but I want it to be if "Column_Name" 1 row below is equal to 13 then ...

Aucun commentaire:

Enregistrer un commentaire