using command line version meme suite to output multiple files
1
1
Entering edit mode
8.6 years ago
kws15 ▴ 40

Hi everyone,

i have a large folder contains thousands of files which all have to be process by meme

the command i used is ' meme FILENAME -mod dna', however the results were overwritten itself everytime , i know i can set the output directory using -o DIRECTORY, but how can i do this in an automatic fashion for all the files may be using a for loop in bash and output the files in different directories??

many thanks

meme suite • 3.5k views
ADD COMMENT
3
Entering edit mode
8.6 years ago
GenoMax 148k
for i in $(ls FILENAME); do mkdir $i\_dir; meme $i -mod dna -o $i\_dir; done

This is just an outline of what can be done. You would want to parse the filename and take parts of it to make the actual output directory name. See @Ram's answer in this bash loop for alignment RNA-seq data for an idea about how to parse file names.

ADD COMMENT
0
Entering edit mode

thank you very much! that works

ADD REPLY

Login before adding your answer.

Traffic: 1609 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6