This is a test version of Biostars. For the public version, visit https://www.biostars.org.
How to cancat two multiplexed fastq files from GBS with two lanes?

Hi! I have been searching for this one the whole morning but couldn't find an answer. Here I have two big fastq files from two lanes for 150 samples. I want to merge the files to a single one, letting each sample on one lane match/merge the same one in the list of the other lane, and keep 150 lanes eventually. So can I concat two multiplexed fastq files without having to demultiplexing them?

Thanks!

snp

I want to merge the files to a single one, letting each sample on one lane match/merge the same one in the list of the other lane, and keep 150 lanes eventually.

It is difficult to understand what you exactly have and what you want but If I am reading this right you have just two files with 150 samples each from 2 lanes? From those you want to create a pair of files per sample which will contain the reads from both lanes?

Are there sample specific index sequences (in the fastq header) in these two files?

If you know the index sequences for each sample then you can use demuxbyname.sh from BBMap suite to get sample specific files for each lane. Then it is just a matter of catting the two lane files together to get your 150 sample files. See: demultiplexing tool for dual-indexed paired-end illumina libraries

Thanks for your reply! Sorry it's hard for me to explain. You‘re right about what I exactly have. But I want to create a single file including all 150 samples instead of 150 files.

In that case just cat the two lane specific files together. Something like:

cat Samples_R1_L001.fq.gz Samples_R1_L002.fq.gz  > Samples_total_R1.fq.gz
cat Samples_R2_L001.fq.gz Samples_R2_L002.fq.gz  > Samples_total_R2.fq.gz

This will put all 150 samples from two lanes into one set of files.

Are you sure its not possible to ask whoever made the fastqs for you to make them the way you want them?

Unfortunately, the people who did the sequencing didn't seem to know how to do it. It maybe a little too specific.

Oh excause me, I just realized I asked a wrong question. Thanks all anyway!

0 answers

No answers yet.

Log in to answer this question.