I have a dictionary that looks like this:
dict = {
"A": [1,2,3],
"B": [4]
}
when I try to create a panda Dataframe I use:
output_df = pd.DataFrame.from_dict(dict, orient='index')
Output:
| - | 1 | 2 | 3 |
|---|---|---|---|
| A | 1 | 2 | 3 |
| B | 4 |
What I want:
| - | 1 |
|---|---|
| A | 1 |
| A | 2 |
| A | 3 |
| B | 4 |
Thanks for your help! :)