I am trying to visualize some data I got using python and bokeh, but it is not working out. It is a .csv file and it looks like this, only then with much more rows and values:
;A;B;C;DA;0;0;1;2;B;0;3;0;0;C;0;0;0;1;D;1;0;2;0
I have tried some stuff, but it did not get me far and now I am kind of stuck.
I tried to make the list with this:
import csv
with open('coauth.csv', 'r') as f:
reader = csv.reader(f)
your_list = list(reader)
print(your_list)
But then it outputs a nested list like this:
[[';A;B;C;D'], ['A;0;0;1;2'], ['B;0;3;0;0']...
And so on.
It would be nice if the output could be something like:
{ 'A' : [0, 0, 1, 2], 'B' : [0, 3, 0, 0],... }
Does someone have an idea of how I should tackle it and maybe also an idea on how to move further with the visualization?