0

I have a dataframe that looks like this:

  category value 
0        A    12
1        B     6
2        C     5
3        D     9
4        A     2
5        B     7
6        C     3
7        D    11

And I'm trying to get to look like this:

 A   B   C   D
12   6   5   9
 2   7   3  11

I've tried using unstack and pivot, but I haven't able to get either to work.

Thanks in advance.

Shark7
  • 509
  • 1
  • 6
  • 8

0 Answers0