i have written code for continues update of data from .csv file ..in this code i have 31 column and 6 rows ..here 1)i dont no how to converte into 2D form and after converting into 2D i want to read my data in column wise in table(how to create table in python for storing the element one after the other column wise )..Can anyone tell me how to read the row[1]column[1] data?..please can anyone help me to solve this problem..
def animate(i):
filename = "tst.csv"
fields = []
rows = []
Nrow = 0
Ncol = 0
cnt_row = 0
cnt_col = 0
with open(filename, 'r') as csvfile:
csvreader = csv.reader(csvfile,delimiter = ",")
data = list(csvreader)
Nrow = len(data)
for row in range(len(data)):
for col in range(len(data[row])):
Ncol = data[row][col].split('.')
print(Ncol)
ani = animation.FuncAnimation(fig, animate, interval=1000)
plt.show()
Column1 Column2
0 4 8
1 6 9
i am expecting the result like this So that i can read my data in column wise