biohazard-1.0.3: bioinformatics support library

Safe HaskellNone
LanguageHaskell2010

Bio.Bam.Writer

Description

Printers for BAM and SAM. BAM is properly supported, SAM can be piped to standard output.

Synopsis

Documentation

class IsBamRec a where Source #

Minimal complete definition

pushBam

Instances
IsBamRec BamRaw Source # 
Instance details

Defined in Bio.Bam.Writer

IsBamRec BamRec Source # 
Instance details

Defined in Bio.Bam.Writer

(IsBamRec a, IsBamRec b) => IsBamRec (Either a b) Source # 
Instance details

Defined in Bio.Bam.Writer

encodeBamWith :: (MonadIO m, IsBamRec r) => Int -> BamMeta -> Enumeratee [r] ByteString m () Source #

Encodes BAM records straight into a dynamic buffer, the BGZF's it. Should be fairly direct and perform well.

writeBamFile :: IsBamRec r => FilePath -> BamMeta -> Iteratee [r] IO () Source #

Writes BAM encoded stuff to a file.

writeBamHandle :: (MonadIO m, IsBamRec r) => Handle -> BamMeta -> Iteratee [r] m () Source #

Writes BAM encoded stuff to a Handle.

pipeBamOutput :: IsBamRec r => BamMeta -> Iteratee [r] IO () Source #

write BAM encoded stuff to stdout This send uncompressed BAM to stdout. Useful for piping to other tools.

pipeSamOutput :: MonadIO m => BamMeta -> Iteratee [BamRec] m () Source #

write in SAM format to stdout This is useful for piping to other tools (say, AWK scripts) or for debugging. No convenience function to send SAM to a file exists, because that's a stupid idea.