I have a dataframe which looks like:

```
   y
0, 0.3234
0, 0.5234
1, 0.3234
1, 0.7854
1, 0.1863
2, 0.0021

```

As you can see there are dplicate indices. when I access by index, it returns all the values with that index. So I decided to split them on the basis of indices like y1 with first value with 0 index, first value with 1 index, first value with 2 index etc. Similarly y2 with second value with 0 index, second value with 1 index, second value with 2 index etc. As the number of times an index appears is not constant, I want the new dataframes y1, y2, y3, y4 etc till the max(number oftimes index occurs for index in y.index) and fill out the remaining values with NaNs.
Like the separated datafraames look like:

y1:

```
   y1
0, 0.3234
1, 0.3234
2, 0.0021 

```

y2:

```
   y2
0, 0.5234
1, 0.7854

```

y3:

```
   y3
1, 0.1863

```

I have tried accessing with index and alist comprehension with [i[0] for i in y.iterrows()] but it does not work either. Any help?