Read Mapping with BWA mem with a bunch of files
1
0
Entering edit mode
18 months ago
zhaoenid • 0

I have 100 sequences that need to map on the reference genome. I use "bwa mem <reference file.fasta=""> <file1.fastq> > file1.sam

how can I perform all those 100 sequences file quickly? i don't really want to do it one by one, match 100times....

next-gen • 426 views
ADD COMMENT
1
Entering edit mode
18 months ago
ATpoint 55k
for i in *.fastq
  do 
  bwa mem reference $i > ${i%.fastq}.sam
  done

Please also use the search function, this has been asked many times before. Please get a background in looping (for loops in bash) or more advanced the use of GNU parallel.

ADD COMMENT

Login before adding your answer.

Traffic: 1323 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