Read .csv file to 2D array as in the file - Not one column
조회 수: 1 (최근 30일)
이전 댓글 표시
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
댓글 수: 0
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Standard File Formats에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!