I have a sample data which likes below. Start and End are paired up in the column.
And I don't know how many rows between one Start and End because of the real data is big.
df = pd.DataFrame({'Item':['Item_A','<Start>','A1','A2','<End>','Item_B','<Start>','B1','B2','B3','<End>']})
print (df)
Item
0 Item_A
1 <Start>
2 A1
3 A2
4 <End>
5 Item_B
6 <Start>
7 B1
8 B2
9 B3
10 <End>
How to change it to the format below with Pandas? Thanks.
