New to Pandas. I had this code originally written to read .csv and now I am writing to read .xlsx files. Anyway, I used if function before to read if Valid Part == 'YES' then ..... follow rest of code.
Now that I am using Pandas I have been testing groupby to achieve my count but haven't quite figured it out.
I am looking in this example if Valid Part == 'Yes' and Appl Req == 'Yes' give me the count.
Any advise is greatly appreciated.
import pandas as pd
df = pd.read_excel('IMPORT.xlsx')
app_req = df.groupby(['Valid Part', 'Appl Req']).count()
print(app_req)
Sample of Data