Posts by Richard Lopes • 21 points
3 posts
-
1
votes0
answers39
viewsQ: How to create a column based on another dataframe?
I would like to know how to create a column on a dataframe based on the code of another Python dataframe. For example, I have: df A: letra c b d c a df B: letra codigo a 10 b 20 c 30 d 40 Expected…
-
1
votes1
answer531
viewsQ: How to delete line from a dataframe based on a python list?
I would like to know how to delete lines from a dataframe based on the accuracy of the values of a column and a list. For example: df: cod letra 101 a 202 b 303 c 404 d 505 e lista = list([202,505])…
conditionasked Richard Lopes 21 -
-1
votes1
answer2035
viewsQ: How to find data based on another column with Pandas?
I own the dataframe dfa: id nome 1 jose 2 pedro 3 maria 3 maria 2 pedro 1 jose And a list with ids: ids = [2, 3] I want a dataframe dfb be the values of dfa filtered on the basis of ids: id nome 2…