You are right cegrant, I mistyped the problem in the original post. Thank you for your support.
Below are exact copy-paste of commands I repeated today (in a directory containing file1.fasta and file2.fasta) to replicate the problem.
while read i; do meme -p 6 -oc ${i}_out $i; done < <(ls | grep .fasta)
while read i; do meme -oc ${i}_out $i; done < <(ls | grep .fasta)
A transcript of the commands and standard out is below. Sorry it's ugly. I can't seem to get the code syntax highlighter to work.
:$ ls
file1.fasta file2.fasta
:$ while read i; do meme -oc ${i}_out $i; done < <(ls | grep .fasta)
Writing results to output directory 'file1.fasta_out'.
BACKGROUND: using background model of order 0
PRIMARY (classic): n 39 p0 39 p1 0 p2 0
SEQUENCE GROUP USAGE-- Starts/EM: p0; Trim: p0; pvalue: p0; nsites: p0,p1,p2
SEEDS: maxwords 15600 highwater mark: seq 39 pos 392
BALANCE: samples 39 chars 15600 nodes 1 chars/node 15600
Initializing the motif probability tables for 2 to 39 sites...
nsites = 39
Done initializing.
seqs= 39, min_w= 400, max_w= 400, total_size= 15600
motif=1
SEED DEPTHS: 2 4 8 16 32 39
SEED WIDTHS: 8 11 15 21 29 41 50
em: w= 50, psites= 39, iter= 0
Writing results to output directory 'file2.fasta_out'.
BACKGROUND: using background model of order 0
PRIMARY (classic): n 39 p0 39 p1 0 p2 0
SEQUENCE GROUP USAGE-- Starts/EM: p0; Trim: p0; pvalue: p0; nsites: p0,p1,p2
SEEDS: maxwords 15600 highwater mark: seq 39 pos 392
BALANCE: samples 39 chars 15600 nodes 1 chars/node 15600
Initializing the motif probability tables for 2 to 39 sites...
nsites = 39
Done initializing.
seqs= 39, min_w= 400, max_w= 400, total_size= 15600
motif=1
SEED DEPTHS: 2 4 8 16 32 39
SEED WIDTHS: 8 11 15 21 29 41 50
em: w= 50, psites= 39, iter= 0
:$ while read i; do meme -p 6 -oc ${i}_out $i; done < <(ls | grep .fasta)
The output directory 'file1.fasta_out' already exists.
Its contents will be overwritten.
BACKGROUND: using background model of order 0
PRIMARY (classic): n 39 p0 39 p1 0 p2 0
SEQUENCE GROUP USAGE-- Starts/EM: p0; Trim: p0; pvalue: p0; nsites: p0,p1,p2
SEEDS: maxwords 15600 highwater mark: seq 39 pos 392
BALANCE: samples 39 chars 15600 nodes 6 chars/node 2600
Initializing the motif probability tables for 2 to 39 sites...
nsites = 36
Done initializing.
seqs= 39, min_w= 400, max_w= 400, total_size= 15600
motif=1
SEED DEPTHS: 2 4 8 16 32 39
SEED WIDTHS: 8 11 15 21 29 41 50
em: w= 50, psites= 2, iter= 0
:$ ls
file1.fasta file1.fasta_out file2.fasta file2.fasta_out