bio-0.4.7: A bioinformatics library




data HashF k Source

This is a struct for containing a set of hashing functions




hash :: SeqData -> Offset -> Maybe k

calculates the hash at a given offset in the sequence

hashes :: SeqData -> [(k, Offset)]

calculate all hashes from a sequence, and their indices

ksort :: [k] -> [k]

for sorting hashes

genkeys :: HashF k -> HashF kSource

Adds a default hashes function to a HashF, when hash is defined.

contigous :: Integral k => Int -> HashF kSource

Contigous constructs an int/eger from a contigous k-word.

rcontig :: Integral k => Int -> HashF kSource

Like contigous, but returns the same hash for a word and its reverse complement.

rcpacked :: Integral k => Int -> HashF kSource

Like rcontig, but ignoring monomers (i.e. arbitrarily long runs of a single nucelotide are treated the same a single nucleotide.

n2k :: Integral k => Int -> SeqData -> kSource

n2i' :: Num a => a -> SeqData -> aSource

k2n :: Integral k => Int -> k -> SeqDataSource

val :: Num t => Char -> tSource

unval :: Num a => a -> CharSource