I'd like to fuse ~50 pairs of corresponding fastq files on per sequence bases. I'd be happy for a solution as a Linux script, R script (if feasible with huge files), or any free software that runs preferably under Debian Linux (otherwise Windows). Aim is preprocessing for a Linux pipeline for NGS data. Ideally both the sequence and quality data are fused.
The aim of this request is the following: there is an existing pipeline for downstream mapping of immunoreceptor sequences (migec/mixcr/vdjtools etc.). Previously we got Illumina reads (read 1, read 2 = reverse), with the index and UMI sequences attached to one of the reads => can be alligned and processed to habe 1 biological useful sequence with UMI and index at one end. NOW we get read 1, read 2 and seperately "read 3" which is just the UMI+Index reads, and which was attached by the core facility to read 1 using software we do not have access to. Since the previous pipeline works well, we prefere to use it in the future, but are open for suggestions how to use the index reads with migec/mixcr/vdjtools otherwise.
Each of the 2 files contains the same number (millions) of short (~300 bp) and corresponding DNA reads:
File_A.fastq:
- @record1 / aaa... / +... / ...
- @record2 / ...
- @record3 / ...
- ... (millions)
File_B.fastq:
- @record1 / ttt... / +... / ...
- @record2 / ...
- @record3 / ...
- ... (millions)
The target file should look like:
- @record1 / aaa...ttt... / +... / ...
- @record2 / ...
- @record3 / ...
- ... (millions)
(of course the aaa...ttt... is just an example)
I was looking for a solution on Stackexchange and Google, but the solutions, I found do not work for me because
- manual processing is not an option given the number of sequences
- I need to fuse the files on a per sequence basis, i.e. a simple Linux command like cat file1 file2 is not what I need (as far as I understand, this would give me (record1_A record2_A.... record1B record2_B).
- R, package shortread, readFastq + writeFastq would be perfect, but cannot handle such large numbers of input lines
Maybe I did not use the right search terms, but in any case I'd be happy for a solution
paste -d "" File_A.fastq File_B.fastq > target.fastq
. This would of course require some clean up first. $\endgroup$