[Python] How to map values into multiple columns of a dataframe

Discussão em 'Python' iniciado por Stack, Abril 16, 2025.

  1. Stack

    Stack Membro Participativo

    Given df1

    id1​
    id2​
    1​
    3​
    4​
    2​
    2​
    1​

    and df2

    id3​
    id4​
    1​
    a​
    2​
    b​
    3​
    c​
    4​
    d​

    I want the results of df1 to be as follows:

    id1​
    id2​
    a​
    c​
    d​
    b​
    b​
    a​

    How can I accomplish this?

    Continue reading...

Compartilhe esta Página