This is a test version of Biostars. For the public version, visit https://www.biostars.org.
In Gkno'S Fastq-Vcf Pipeline, Can I Write To Disk An Intermediary Bam Aligment Currently Sent To The Stream?

Hi,

I'm using gkno's 'fastq-vcf' pipeline as a way to run a serial of steps for variant calling. gkno allows the use of bash streams to pipe data between tools without ever writing to disk.

I was wondering if there is away to keep the BAM alignment coming out of "left-align-indels" step in this pipeline. I can see these three steps are writing to the stream: "filter-bam", "realign-gaps", "left-align-indels"

And "variant-call"(freebayes) is the receptor of the final stream. I would like to instead save the intermediary BAM file for further visualization and analysis. If this is possible, do you think this change would cause a big performance hit?

I did look at bamleftalign's(tool used for "left-align-indels" step), it seems like the only option is to write to the stream. Is that right?

2 answers

I have modified how output streams are handled and included an additional pipeline - fastq-bam. This pipeline is identical to the fastq-vcf pipeline except that it terminates after left-aligning indels and produces a BAM file as output. Please update to the most recent version of GKNO and these changes should be available.

Perhaps you could insert an instance of the UNIX tee command, piping streamed intermediate data to a named pipe that you can process separately. As this is a bash or other shell script, you should be able to read the script and insert the tee statement where you need it.

That's a good suggestion. I might have to integrate 'tee' as a tool in gkno. If I do, that could meant I can easily grab the stream coming out of tools which currently only write to the stream.

Thanks, I will explore this option.

Log in to answer this question.