Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- name number ID code
- 1111 2 3 ['%AB','$12','&FD']
- name number ID to from
- 1111 2 3 %AB $12
- 1111 2 3 %AB &FD
- 1111 2 3 $12 &FD
- a = [y for x in df[['code']].stack() for y in combinations(x,2)]
- df[['to','from']] = a
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement