I tried to set some values in a dataframe to empty based on a condition in python. The code is something like this,
df.loc[df['Col1'] > 0.5, 'Col2'] = np.nan
However, in output file (.csv), it's "nan" there. So wondering if there are any ways to make it empty? Thanks.