python-novice-gapminder icon indicating copy to clipboard operation
python-novice-gapminder copied to clipboard

Revise section on dataframe slicing

Open henrikaskj opened this issue 4 years ago • 0 comments

I would suggest revising the section "Use : on its own to mean all columns or all rows", as it isn't strictly necessary to know that a colon without begin and end value results in a whole list (cf. thing[:] in the exercise in episode 2). One could instead focus on ​data.loc["Albania"] and data["gdpPercap_1952"], and add an explanation of how to select non-continuous rows and columns, e. g. data.loc[["Albania", "Turkey"]]

henrikaskj avatar Jun 24 '21 13:06 henrikaskj