MATLAB: How to read the tab delimited with skipping the first row

tab delimited ampl file

I want to skip the first row because the function 'tdfread' cannot read the file with first row "ampl.tab 3 1" File Structure:
ampl.tab 3 1
r p t Ox
1 1 0 0
1 1 1 0
1 1 2 0
1 1 3 0

Best Answer

I would use the textscan function instead. Something like this would work:
fidi = fopen(filename,'rt');
D = textscan(fidi, '%f%f%f%f', 'Delimiter','\t', 'HeaderLines',2, 'CollectOutput',1);
Experiment with it to get the result you want.