Merge 4 Fastq Files
I know there have been many questions regarding merging fastq files. But I am not getting relevant answers in my situation.
I have 4 paired-ended fastq files.
Can I just cat the first two files and the last two files to make s_6.fastq and s_7.fastq? I would like to use these fastq files for mapping with BWA or Bowtie.
Hope to get some suggestions regarding this.
Try this. Mostly default settings. Where I say "-t 4" I am assuming you have 4 processors. You can drop this number if that's not the case for you.
bwa index -p mygenome -a bwtsw mygenome.fa
bwa aln -t 4 bwtsw mygenome s_6_1.fastq > s_6_1.sai
bwa aln -t 4 bwtsw mygenome s_6_2.fastq > s_6_2.sai
bwa sampe mygenome s_6_1.sai s_6_2.sai s_6_1.fastq s_6_2.fastq > s_6.sam
Merging seems unnecessarily complicated in this case. I don't know if
bwa can handle that.
If you would like to merge the files, in your case...the merging should be..
Sample1_r1 + Sample2_r1 = Sample_r1.fastq && Sample1_r2 + Sample2_r2 = Sample_r2.fastq
Then align using bowtie2.
bowtie2 -x Genome_Index -1 Sample_r1.fastq -2 Sample_r2.fastq -S out.sam
Traffic: 2236 users visited in the last hour