MATLAB: Importing csv file into matlab

csvreaddata uploading

Hi,
I am having error while using csv read for the following file.
num = csvread (FileName,2,0);
Error using dlmread (line 143)
Mismatch between file and format string.
Trouble reading 'Numeric' field from file (row number 1, field number 57) ==>
N,N,N,N,N,N,N,Y,N,N\n
Is there a way to read the following sheet into matlab.
Thanks…!!!!

Best Answer

csvread() is unable to read files with text, with the possible exception of header rows and maybe leading columns of text -- definitely not text at the end of lines.
If you have R2013b or later, I suggest you use
datatab = readtable('matlab_upload.csv', 'headerlines', 1);