
上QQ阅读APP看书,第一时间看更新
Removing NaN values
Next, we are going to remove NaN values from the field.
We can do this as follows:
dfs = dfs[dfs['date'].notna()]
Next, it is good to save the preprocessed file into a separate CSV file in case we need it again. We can save the dataframe into a separate CSV file as follows:
dfs.to_csv('gmail.csv')
Great! Having done that, let's do some descriptive statistics.