In Python Pandas, I use a Data Frame as such:
drinks = pandas.read_csv(data_url)
Where data_url is the string URL of the CSV file
When indexing the framework for all “easy drinkers,” where light drinkers make up 1 drink, it says:
drinks.light_drinker[drinks.light_drinker == 1]
Is there a more DRY-like way to independently refer to the "parent"? That is, something like:
drinks.light_drinker[self == 1]
source
share