Skip to content

How to get a simliar functionality as loc in pandas #1867

Answered by yohplala
derrickcchow asked this question in Q&A
Discussion options

You must be logged in to vote

Hi, I was wondering if there is a way to implement something similar to loc in pandas in vaex. This is the code: df.loc[df["Variable Value"] == x, columnname] = value

thanks, Derrick

Hi, for such a pattern, you should head to where.
From API documentation (I would have used a link, would there be one for individual function)

Bests

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by derrickcchow
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants