Hi,
I want to copy txt-files only from multiple directories. All the directories (Run 1 ~l Run N) are sub dir's of a dir called DATA, e.g:
-> Run 1: bla.txt, ready.xls, clear.doc
DATA -> Run 2: esp.txt, fey.txt, show.xls
-> Run N: ...
So, I just want to copy bla.txt, esp.txt and fey.txt to 1 directory, let's say C:\test\
How can I fix this in matlab?
|
|
0
|
|
|
|
Reply
|
ddie
|
4/5/2010 3:42:06 PM |
|
"@ddie ertser" <ivogrunn@hotmail.com> wrote in message <hpd0ce$f57$1@fred.mathworks.com>...
> Hi,
>
> I want to copy txt-files only from multiple directories. All the directories (Run 1 ~l Run N) are sub dir's of a dir called DATA, e.g:
>
> -> Run 1: bla.txt, ready.xls, clear.doc
> DATA -> Run 2: esp.txt, fey.txt, show.xls
> -> Run N: ...
>
> So, I just want to copy bla.txt, esp.txt and fey.txt to 1 directory, let's say C:\test\
>
> How can I fix this in matlab?
a hint:
help copyfile;
% then, drill all the way down to NOTE 2...
us
|
|
0
|
|
|
|
Reply
|
us
|
4/5/2010 3:48:04 PM
|
|
"us " <us@neurol.unizh.ch> wrote in message <hpd0nk$krs$1@fred.mathworks.com>...
> "@ddie ertser" <ivogrunn@hotmail.com> wrote in message <hpd0ce$f57$1@fred.mathworks.com>...
> > Hi,
> >
> > I want to copy txt-files only from multiple directories. All the directories (Run 1 ~l Run N) are sub dir's of a dir called DATA, e.g:
> >
> > -> Run 1: bla.txt, ready.xls, clear.doc
> > DATA -> Run 2: esp.txt, fey.txt, show.xls
> > -> Run N: ...
> >
> > So, I just want to copy bla.txt, esp.txt and fey.txt to 1 directory, let's say C:\test\
> >
> > How can I fix this in matlab?
>
> a hint:
>
> help copyfile;
> % then, drill all the way down to NOTE 2...
>
> us
I already did... But you have to do it for all the directories (Run 1 ~ Run N) seperatly. So I'm searching for a command which copies all txt-files from DATA and it's subdirectories.
|
|
0
|
|
|
|
Reply
|
ddie
|
4/5/2010 3:56:06 PM
|
|
"@ddie ertser" <ivogrunn@hotmail.com> wrote in message <hpd16m$sge$1@fred.mathworks.com>...
> "us " <us@neurol.unizh.ch> wrote in message <hpd0nk$krs$1@fred.mathworks.com>...
> > "@ddie ertser" <ivogrunn@hotmail.com> wrote in message <hpd0ce$f57$1@fred.mathworks.com>...
> > > Hi,
> > >
> > > I want to copy txt-files only from multiple directories. All the directories (Run 1 ~l Run N) are sub dir's of a dir called DATA, e.g:
> > >
> > > -> Run 1: bla.txt, ready.xls, clear.doc
> > > DATA -> Run 2: esp.txt, fey.txt, show.xls
> > > -> Run N: ...
> > >
> > > So, I just want to copy bla.txt, esp.txt and fey.txt to 1 directory, let's say C:\test\
> > >
> > > How can I fix this in matlab?
> >
> > a hint:
> >
> > help copyfile;
> > % then, drill all the way down to NOTE 2...
> >
> > us
>
> I already did... But you have to do it for all the directories (Run 1 ~ Run N) seperatly. So I'm searching for a command which copies all txt-files from DATA and it's subdirectories.
well... currently not possible in ML...
you may have to call a system command...
help system;
help unix;
help dos;
us
|
|
0
|
|
|
|
Reply
|
us
|
4/5/2010 4:03:10 PM
|
|
"@ddie ertser" <ivogrunn@hotmail.com> wrote in message
news:hpd16m$sge$1@fred.mathworks.com...
> "us " <us@neurol.unizh.ch> wrote in message
> <hpd0nk$krs$1@fred.mathworks.com>...
>> "@ddie ertser" <ivogrunn@hotmail.com> wrote in message
>> <hpd0ce$f57$1@fred.mathworks.com>...
>> > Hi,
>> >
>> > I want to copy txt-files only from multiple directories. All the
>> > directories (Run 1 ~l Run N) are sub dir's of a dir called DATA, e.g:
>> >
>> > -> Run 1: bla.txt, ready.xls, clear.doc
>> > DATA -> Run 2: esp.txt, fey.txt, show.xls
>> > -> Run N: ...
>> >
>> > So, I just want to copy bla.txt, esp.txt and fey.txt to 1 directory,
>> > let's say C:\test\
>> >
>> > How can I fix this in matlab?
>>
>> a hint:
>>
>> help copyfile;
>> % then, drill all the way down to NOTE 2...
>>
>> us
>
> I already did... But you have to do it for all the directories (Run 1 ~
> Run N) seperatly. So I'm searching for a command which copies all
> txt-files from DATA and it's subdirectories.
There's no such commend built-in to MATLAB, but a little bit of work with
DIR, COPYFILE (already mentioned), and GENPATH could give you what you need.
--
Bob Gilmore, The MathWorks, Inc.
|
|
0
|
|
|
|
Reply
|
Bob
|
4/5/2010 7:27:45 PM
|
|
|
4 Replies
389 Views
(page loaded in 0.042 seconds)
|