Azzera filtri
Azzera filtri

Read .csv file to 2D array as in the file - Not one column

1 visualizzazione (ultimi 30 giorni)
Please help me in the following:
I have a .csv file contains several rows and just one column .. Each cell contain long string which is separated by tab (string and integers)
For example as follows
"userid tz call_time status direction description number_prefix number in_phonebook duration"
"18672001271175066DeliveredIncomingShortmessage10495811f0c88324863d7e1a0205874c36ba4aedee737ed06708f1c2104192ad 0 0"
"18672001271175095DeliveredIncomingShort message10495811f0c88324863d7e1a0205874c36ba4aedee737ed06708f1c2104192ad 00"
Each phrase is contained in 1 cell
I want to convert it to 2d matrices in matlab in order to convert it to . mat file as follows:
Userid tz call_time status ... 186 7200 1271175
I used textread('file.csv', '%s') ans the result was as follows:
Userid tz call_time status ... 186 7200 1271175
1D ans all in just one column..
Could any one help

Risposte (0)

Tag

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by