I have a list with some counts with 5 elements.
counts = [33, 35, 17, 38, 29]
This counts list is updated with new numbers every day. So I wanted to create a dataframe and append the counts data as a new row every day. Every element of the list should appear in separate column in the dataframe. What i want to do is the following:
df = pd.DataFrame(columns = ['w1', 'w2', 'w3', 'w4', 'w5'])
df = df.append(counts)
but instead of adding counts data as a row, it adds a new column. Any help on how to do this correctly?
Assume counts on day0 is [33, 35, 17, 38, 29] and on day1 is [30, 36, 20, 34, 32], what i want is the following as output:
w1 w2 w3 w4 w5
0 33 35 17 38 29
1 30 36 20 34 32
where index represent the day at which counts were taken. any help?