Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
# Change the first name of all rows with an ID greater than 2000 to "John"
data.loc[data['id'] > 2000, "first_name"] = "John"
# Change the first name of all rows with an ID greater than 2000 to "John"
data.loc[data['id'] > 2000, "first_name"] = "John"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment