Hello,
I have a dictionary in this way
tdm={
word1: [0,0,0,1.....] -> 253 values in the list
word2: [0,25,0,2.....]
.
.
.
word 12,000: [0,30,0,1.....]
}
I want it to be converted to this form in CSV
TERM | 0 | 1 | 2 | ....... 252 |
------------------------------------|
word1 | 0 | 0 | 0 | ..........
word2 | 0 | 25 | 0 | .........
..
..
word12,000
----------------------------------
Can anyone please help me with this...I'm unable to find a way for more than 5 hrs now
I have a dictionary in this way
tdm={
word1: [0,0,0,1.....] -> 253 values in the list
word2: [0,25,0,2.....]
.
.
.
word 12,000: [0,30,0,1.....]
}
I want it to be converted to this form in CSV
TERM | 0 | 1 | 2 | ....... 252 |
------------------------------------|
word1 | 0 | 0 | 0 | ..........
word2 | 0 | 25 | 0 | .........
..
..
word12,000
----------------------------------
Can anyone please help me with this...I'm unable to find a way for more than 5 hrs now