cobot-0.1.1.4: Computational biology toolkit to collaborate with researchers in constructive protein engineering

Safe HaskellNone
LanguageHaskell2010

Bio.Chain.Alignment.Type

Synopsis

Documentation

type Scoring a b = a -> b -> Int Source #

Scoring function, returns substitution score for a couple of elements

type Scoring = Char -> Char -> Int

type SimpleGap = Int Source #

Simple gap penalty

type SimpleGap2 = (SimpleGap, SimpleGap) Source #

Gap penalty with different SimpleGap penalties for sequences.

First element of pair is penalty for first sequence passed to alignment algorithm, second element — penalty for second passed sequence.

data AffineGap Source #

Affine gap penalty

Constructors

AffineGap 

Fields

Instances
Eq AffineGap Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Show AffineGap Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Generic AffineGap Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Associated Types

type Rep AffineGap :: Type -> Type #

NFData AffineGap Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Methods

rnf :: AffineGap -> () #

IsGap AffineGap2 Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

IsGap AffineGap Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

type Rep AffineGap Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

type Rep AffineGap = D1 (MetaData "AffineGap" "Bio.Chain.Alignment.Type" "cobot-0.1.1.4-DktzNSutq99J6cVYSuTVxT" False) (C1 (MetaCons "AffineGap" PrefixI True) (S1 (MetaSel (Just "gapOpen") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Int) :*: S1 (MetaSel (Just "gapExtend") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Int)))

type AffineGap2 = (AffineGap, AffineGap) Source #

Gap penalty with different AffineGap penalties for sequences.

First element of pair is penalty for first sequence passed to alignment algorithm, second element — penalty for second passed sequence.

class IsGap a where Source #

Type class that describes possible gaps in alignments.

Methods

insertCostOpen :: a -> Int Source #

Insertions are gaps in the first argument of an alignment function.

insertCostExtend :: a -> Int Source #

deleteCostOpen :: a -> Int Source #

Deletions are gaps in the second argument of an alignment function.

deleteCostExtend :: a -> Int Source #

isAffine :: a -> Bool Source #

data EditOp Source #

Edit operation could be insertion, deletion or match/mismatch

Constructors

Insert 
Delete 
Match 
Instances
Bounded EditOp Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Enum EditOp Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Eq EditOp Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Methods

(==) :: EditOp -> EditOp -> Bool #

(/=) :: EditOp -> EditOp -> Bool #

Ord EditOp Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Show EditOp Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Ix EditOp Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Generic EditOp Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Associated Types

type Rep EditOp :: Type -> Type #

Methods

from :: EditOp -> Rep EditOp x #

to :: Rep EditOp x -> EditOp #

NFData EditOp Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Methods

rnf :: EditOp -> () #

(NFData a, NFData b) => NFData (UArray (a, b, EditOp) Int) Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Methods

rnf :: UArray (a, b, EditOp) Int -> () #

type Rep EditOp Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

type Rep EditOp = D1 (MetaData "EditOp" "Bio.Chain.Alignment.Type" "cobot-0.1.1.4-DktzNSutq99J6cVYSuTVxT" False) (C1 (MetaCons "Insert" PrefixI False) (U1 :: Type -> Type) :+: (C1 (MetaCons "Delete" PrefixI False) (U1 :: Type -> Type) :+: C1 (MetaCons "Match" PrefixI False) (U1 :: Type -> Type)))

data Operation i j Source #

Operation that was performed on current step of alignment

Constructors

INSERT 

Fields

DELETE 

Fields

MATCH 

Fields

Instances
(Eq j, Eq i) => Eq (Operation i j) Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Methods

(==) :: Operation i j -> Operation i j -> Bool #

(/=) :: Operation i j -> Operation i j -> Bool #

(Ord j, Ord i) => Ord (Operation i j) Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Methods

compare :: Operation i j -> Operation i j -> Ordering #

(<) :: Operation i j -> Operation i j -> Bool #

(<=) :: Operation i j -> Operation i j -> Bool #

(>) :: Operation i j -> Operation i j -> Bool #

(>=) :: Operation i j -> Operation i j -> Bool #

max :: Operation i j -> Operation i j -> Operation i j #

min :: Operation i j -> Operation i j -> Operation i j #

(Show j, Show i) => Show (Operation i j) Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Methods

showsPrec :: Int -> Operation i j -> ShowS #

show :: Operation i j -> String #

showList :: [Operation i j] -> ShowS #

Generic (Operation i j) Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Associated Types

type Rep (Operation i j) :: Type -> Type #

Methods

from :: Operation i j -> Rep (Operation i j) x #

to :: Rep (Operation i j) x -> Operation i j #

(NFData j, NFData i) => NFData (Operation i j) Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Methods

rnf :: Operation i j -> () #

type Rep (Operation i j) Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

type Rep (Operation i j) = D1 (MetaData "Operation" "Bio.Chain.Alignment.Type" "cobot-0.1.1.4-DktzNSutq99J6cVYSuTVxT" False) (C1 (MetaCons "INSERT" PrefixI True) (S1 (MetaSel (Just "getJ") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 j)) :+: (C1 (MetaCons "DELETE" PrefixI True) (S1 (MetaSel (Just "getI") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 i)) :+: C1 (MetaCons "MATCH" PrefixI True) (S1 (MetaSel (Just "getI") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 i) :*: S1 (MetaSel (Just "getJ") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 j))))

type Matrix m m' = UArray (Index m, Index m', EditOp) Int Source #

Alignment matrix type

type Stop m m' = Matrix m m' -> m -> m' -> Index m -> Index m' -> Bool Source #

Traceback stop condition type

type Move m m' Source #

Arguments

 = Matrix m m' 
-> m 
-> m' 
-> Index m 
-> Index m' 
-> EditOp

Current matrix, used in affine alignment

-> (EditOp, Index m, Index m', Operation (Index m) (Index m'))

Next matrix, next indices, new operation

Traceback next move generator type

data Conditions m m' Source #

A set of traceback conditions

Constructors

Conditions 

Fields

data AlignmentResult m m' Source #

Sequence Alignment result

Constructors

AlignmentResult 

Fields

Instances
Generic (AlignmentResult m m') Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Associated Types

type Rep (AlignmentResult m m') :: Type -> Type #

Methods

from :: AlignmentResult m m' -> Rep (AlignmentResult m m') x #

to :: Rep (AlignmentResult m m') x -> AlignmentResult m m' #

(NFData a, NFData b, NFData (Index a), NFData (Index b)) => NFData (AlignmentResult a b) Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

Methods

rnf :: AlignmentResult a b -> () #

type Rep (AlignmentResult m m') Source # 
Instance details

Defined in Bio.Chain.Alignment.Type

type Rep (AlignmentResult m m') = D1 (MetaData "AlignmentResult" "Bio.Chain.Alignment.Type" "cobot-0.1.1.4-DktzNSutq99J6cVYSuTVxT" False) (C1 (MetaCons "AlignmentResult" PrefixI True) ((S1 (MetaSel (Just "score") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 Int) :*: S1 (MetaSel (Just "alignment") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 [Operation (Index m) (Index m')])) :*: (S1 (MetaSel (Just "sequence1") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 m) :*: S1 (MetaSel (Just "sequence2") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 m'))))

type Alignable m = (ChainLike m, Ix (Index m)) Source #

Chain, that can be used for alignment

class SequenceAlignment (a :: * -> * -> *) where Source #

Method of sequence alignment

Minimal complete definition

cond, traceStart, scoreMatrix

Methods

semi :: a e1 e2 -> Bool Source #

Defines wheater the alignment is semiglobal or not

cond :: (Alignable m, Alignable m') => a (IxValue m) (IxValue m') -> Conditions m m' Source #

Traceback conditions of alignment

traceStart :: (Alignable m, Alignable m') => a (IxValue m) (IxValue m') -> Matrix m m' -> m -> m' -> (Index m, Index m') Source #

Starting position in matrix for traceback procedure

scoreMatrix :: (Alignable m, Alignable m') => a (IxValue m) (IxValue m') -> m -> m' -> Matrix m m' Source #

Distance matrix element

Instances
IsGap g => SequenceAlignment (SemiglobalAlignment g) Source # 
Instance details

Defined in Bio.Chain.Alignment.Algorithms

Methods

semi :: SemiglobalAlignment g e1 e2 -> Bool Source #

cond :: (Alignable m, Alignable m') => SemiglobalAlignment g (IxValue m) (IxValue m') -> Conditions m m' Source #

traceStart :: (Alignable m, Alignable m') => SemiglobalAlignment g (IxValue m) (IxValue m') -> Matrix m m' -> m -> m' -> (Index m, Index m') Source #

scoreMatrix :: (Alignable m, Alignable m') => SemiglobalAlignment g (IxValue m) (IxValue m') -> m -> m' -> Matrix m m' Source #

IsGap g => SequenceAlignment (LocalAlignment g) Source # 
Instance details

Defined in Bio.Chain.Alignment.Algorithms

Methods

semi :: LocalAlignment g e1 e2 -> Bool Source #

cond :: (Alignable m, Alignable m') => LocalAlignment g (IxValue m) (IxValue m') -> Conditions m m' Source #

traceStart :: (Alignable m, Alignable m') => LocalAlignment g (IxValue m) (IxValue m') -> Matrix m m' -> m -> m' -> (Index m, Index m') Source #

scoreMatrix :: (Alignable m, Alignable m') => LocalAlignment g (IxValue m) (IxValue m') -> m -> m' -> Matrix m m' Source #

IsGap g => SequenceAlignment (GlobalAlignment g) Source # 
Instance details

Defined in Bio.Chain.Alignment.Algorithms

Methods

semi :: GlobalAlignment g e1 e2 -> Bool Source #

cond :: (Alignable m, Alignable m') => GlobalAlignment g (IxValue m) (IxValue m') -> Conditions m m' Source #

traceStart :: (Alignable m, Alignable m') => GlobalAlignment g (IxValue m) (IxValue m') -> Matrix m m' -> m -> m' -> (Index m, Index m') Source #

scoreMatrix :: (Alignable m, Alignable m') => GlobalAlignment g (IxValue m) (IxValue m') -> m -> m' -> Matrix m m' Source #