eval - data file that includes headers
eval - data file that includes headers
(OP)
All,
I try to create an array with some data files and the code I use is the next one:
files=dir('F:\Strain Data\January\*.dat');
d={};
for i=1:length(files)
eval(['d{' int2str(i) '}=load(files(' int2str(i) ').name);']);
end
The code seems to work. However, my data files have headers! In that case the function "load" does not apply!!!
Any help?
I try to create an array with some data files and the code I use is the next one:
files=dir('F:\Strain Data\January\*.dat');
d={};
for i=1:length(files)
eval(['d{' int2str(i) '}=load(files(' int2str(i) ').name);']);
end
The code seems to work. However, my data files have headers! In that case the function "load" does not apply!!!
Any help?
RE: eval - data file that includes headers
I think this is the last post in which I do your assignment for you.
Cheers
Greg Locock
New here? Try reading these, they might help FAQ731-376: Eng-Tips.com Forum Policies http://eng-tips.com/market.cfm?
RE: eval - data file that includes headers
But thank you for your time. However, if that's how feel please do not answer any of my next questions. I hope I didn't force you to do so far. But really thank you especially for the first time you answered my question. It gave me a really good idea about which concept to follow in the beginning.
RE: eval - data file that includes headers
Cheers
Greg Locock
New here? Try reading these, they might help FAQ731-376: Eng-Tips.com Forum Policies http://eng-tips.com/market.cfm?
RE: eval - data file that includes headers
http://www.eng-tips.com/viewthread.cfm?qid=342002
Before you burn all your bridges on this forum, please contribute to the spirit of helping others by posting your solution.
RE: eval - data file that includes headers
In case anyone stumbles across this thread looking for an answer, one solution might be to use the dlmread command, which allows you to skip header rows.
CODE --> Matlab
This is not as complicated as the OP suggested.
http://www.mathworks.com/help/matlab/ref/dlmread.h...