This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Storing Fastq As Unaligned Bam

Hey Guys

Just wondering if anyone there is now storing the raw fastq data as unaligned bam files. We are reaching a stage where any space we could potentially save would be beneficial.

Any con of storing fastq as bam? I see some discussion about this on seqanswers: http://seqanswers.com/forums/showthread.php?t=14941

Also any tools that people already have that converts a fastq to bam and vice-a-versa. I know there are few which can do bam to fastq like picard but not sure if fastq to bam is there.

Thanks!

Abhi

bam fastq

This doesn't read like a stackexcahnge question to me - if you want a discussion why not continue on SEQanswers?

This seems relevant to me, handling large NGS data files is an increasing bioinformatic issue.

2 answers

I think a bgzipped fastq file will be always smaller than a BAM file as the BAM file also contains the positions of the alignments.

See also:

http://bioinformatics.oxfordjournals.org/content/early/2011/01/19/bioinformatics.btr014.abstract

Compression of genomic sequences in FASTQ format

and

http://genome.cshlp.org/content/early/2011/01/18/gr.114819.110

Efficient storage of high throughput sequencing data using reference-based compression

Hi Abhi,

yes we do this in our team. You can use Picard 'FastqToSam' utility.

Compared to 2 fastq files (plain, not gzipped as suggested by Pierre), an unaligned BAM file allows to save 60°% to 65% of storage space. It is also practical because you can store some useful information (Sample, Library, Run, any useful comments ...) in the header if you want to.

Log in to answer this question.