Apply changes proposed by @deppen8 in #467 and #468, but without styling "pandas" with backticks.
Make references more explicitly to "pandas" rather than "Python"
Add lots of code style formatting where appropriate
Replace references to isnull() with isna(). These methods are exactly the same for pandas, but isna() is consistent with fillna, dropna, etc. which are also used here.
Replaced a reference to survey_df.weight with survey_df['weight'], the preferred notation style for pandas
I had to do this as a new PR because the branches had been deleted for both PRs, which prevented me from editing the file there.
Supersedes #467 & #468
Apply changes proposed by @deppen8 in #467 and #468, but without styling "pandas" with backticks.
code
style formatting where appropriateisnull()
withisna()
. These methods are exactly the same for pandas, butisna()
is consistent withfillna
,dropna
, etc. which are also used here.survey_df.weight
withsurvey_df['weight']
, the preferred notation style for pandasI had to do this as a new PR because the branches had been deleted for both PRs, which prevented me from editing the file there.