Re: conactenate using a loop



not sure what "dlmread(cat(1,files(j,1).name))" is supposed
to do (what is the cat() doing there)?, but generally you
would do what you want like this:

alldata = [];
for j=1:number_of_files_to_read;
data = read_data_and_return_your_array(filename);
alldata = [alldata; data];
end

Also, it might be handier to make a new list only
containing the filenames of files you want to read in and
not the others, then you can simply loop over that list and
do not have to create that vectorX
.



Relevant Pages

  • Re: Scilab question: cat takes too long w/ large amounts of data, whats an alternative function?
    ... The problem is that since i'm working with audio data, ... and cat takes longer every time the for loop ... Are there any alternative functions that i could use instead of cat, ... Scilab does not _require_ declaring/dimensioning an array before use which allows us to be a little sloppy. ...
    (comp.dsp)
  • Re: filter in perl
    ... Using "exit" to break out of a loop is overkill (you can take that ... Give the outer loop a label, ...
    (comp.lang.perl.misc)
  • Re: how to construct an array from another one !!
    ... The output B sould be as follows: ... while flag ... So now it just takes a loop over ... The best material model of a cat is another, or preferably the same, cat. ...
    (comp.soft-sys.matlab)
  • Re: Matrix Mult. Question
    ... The best way to do this without a loop and without ... some variant of repmat or a mex function is with a ... The best material model of a cat is another, or preferably the same, cat. ...
    (comp.soft-sys.matlab)
  • Re: loop
    ... No, if it's a fifo, then cat will block until the other end ... closes the pipe, and then and only then, the loop will start. ... finishes) and stores the result in memory. ...
    (comp.unix.shell)