Skip to content

String "None" interpreted as NaN in newer versions of pandas #15

Description

@readyready15728

The preprocessing code for chapter 12 doesn't work anymore. There are "None" strings for the holiday field of Metro_Interstate_Traffic_Volume.csv and newer versions of pandas interpret them as NaN. This can be fixed with the following modified call to pd_read_csv():

df = pd.read_csv('../data/Metro_Interstate_Traffic_Volume.csv', na_values=[], keep_default_na=False)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions