I have the following DataFrame:
| Category | score_1 | score_2 | score_3 |
|---|---|---|---|
| A | 0.23 | 0.14 | 0.19 |
| B | 0.50 | 0.55 | 0.60 |
| C | 0.21 | 0.34 | 0.30 |
I would like to transform the previous DataFrame into the following one:
| Scores | Category | Value |
|---|---|---|
| score_1 | A | 0.23 |
| score_1 | B | 0.14 |
| score_1 | C | 0.19 |
| score_2 | A | 0.50 |
| score_2 | B | 0.55 |
| score_2 | C | 0.60 |
| score_3 | A | 0.21 |
| score_3 | B | 0.34 |
| score_3 | C | 0.30 |
Is there any method in pandas to perform this kind of operation?