I have a DF, Sample below:
Group $ Type
1 50 A
1 0 B
1 0 C
2 150 A
2 0 B
2 0 C
What I want to do is populate the $
column with the value associated with the column A
, by each group.
Resulting DF will look like the below:
Group $ Type
1 50 A
1 50 B
1 50 C
2 150 A
2 150 B
2 150 C
I have tried various np.where functions but can't seem to get the desired output.
Thanks in advance!