How to replace values in Dataframe based on multiple conditions?
how about using quick-sort algorithm. And, I am not sure I got what your data looks like and what results you want to obtain. Maybe you could show us parts of your data frame.
I have one large dataframe that currently has both "?", "??", and NaN values that I'm trying to remove. I want to redefine the columns to be booleans to see whether they contained "?", "??" or NaN.
My current approach involves cloning different columns of the dataframe based on whether they contain just "?", just "??" or just NaN values and separately iterating through the columns, col, to change the values (ex: df[col] = df[col].isnull()) and finally merging them together again.
Is there an easier way to do this?