Change Array To Dataframe In Python Syntax If Statement