pandas pd check if column exist code example Example: check if column exists in dataframe python if 'A' in df: