I've been trying to do some DataFrame manipulation but I can't find how to do this. I've a DataFrame like this :
Iso-2 FAOSTAT Production % Solde %
0 CN 41 0.247561 NaN
10 US 231 0.162421 NaN
14 AR 9 0.012170 NaN
21 GR 84 0.012737 NaN
0 CN 41 NaN 0.321039
6 ID 101 NaN 0.032065
7 UZ 235 NaN 0.031848
8 MX 138 NaN 0.022452
I want to gather the values of the third and fourth column in the same row where the first and second are the same. I'd like to have something like this :
Iso-2 FAOSTAT Production % Solde %
0 CN 41 0.247561 0.321039
10 US 231 0.162421 NaN
14 AR 9 0.012170 NaN
21 GR 84 0.012737 NaN
6 ID 101 NaN 0.032065
7 UZ 235 NaN 0.031848
8 MX 138 NaN 0.022452
Any help would be greatly appreciated, and sorry if the post isn't the best you have ever looked it's my first one.