I am wondering if I can pipe output from
reformat.sh in BBMap into SAMtools
view. My goal is to take a set of fastq and return an unaligned BAM headed with sequence dictionary (this is for use in GATK4). Using some GATK test data this part works (of course!):
bbduk.sh in1=6484_snippet_1.fastq in2=6484_snippet_2.fastq trimq=30 out=stdout.fq | reformat.sh in=stdin.fq out=stdout.bam
I suppose the question then is: can I force reformat.sh to produce a BAM without specifying
".bam" ending? Or, what form does 'stdout.bam' take and how can SAMtools recognise it? Or, can reformat.sh do the reheader itself?
All help much appreciated,