This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Select rows with first name Antonio, # and all columns between 'city' and 'email' | |
data.loc[data['first_name'] == 'Antonio', 'city':'email'] | |
# Select rows where the email column ends with 'hotmail.com', include all columns | |
data.loc[data['email'].str.endswith("hotmail.com")] | |
# Select rows with last_name equal to some values, all columns | |
data.loc[data['first_name'].isin(['France', 'Tyisha', 'Eric'])] | |