May-03-2022, 08:00 PM
Hello Everyone.
I am new to the Python and this Forum. I have the requirement to generate the new set of dataset
Source Dataset
ID SRC_VAL TGT_VAL
1 A [B,C]
2 D [E,F]
3 G [B,H]
Output dataset
ID SRC_VAL
B 1
C 1
E 2
F 2
B 3
H 3
The Desired output is
ID SRC_VAL
B [1,3]
C [1]
E [2]
H [3]
F [ 2]
Can anyone help me in getting the desired output.
Thanks in Advance
I am new to the Python and this Forum. I have the requirement to generate the new set of dataset
Source Dataset
ID SRC_VAL TGT_VAL
1 A [B,C]
2 D [E,F]
3 G [B,H]
Output dataset
ID SRC_VAL
B 1
C 1
E 2
F 2
B 3
H 3
The Desired output is
ID SRC_VAL
B [1,3]
C [1]
E [2]
H [3]
F [ 2]
Can anyone help me in getting the desired output.
Thanks in Advance