Im trying to import large txt files (> 1gb) into matlab.
this is a data structure:
667.55535 -0.00 0.000 0.0158 667.5554 -0.01 -0.000 0.0158 667.55545 -0.01 4.037 10.0000 667.5555 -0.00 4.000 10.0000 #1 Trigger Camera 10 Hz #2 Trigger Camera 10 Hz 667.55555 -0.00 4.000 10.0000 667.5556 -0.01 4.000 10.0000
I am using the textscan function:
segarray = textscan(file_id, '%f %f %f %f', blocksize, 'delimiter','\n', 'commentStyle', '#');
works very well, but I need comments marked with a "#" if I change the format string to "% f% f% f% f% s" and delete the parameter "commentStyle", "#" every second line is read as one line : /
any ideas?
source share