bioinformatics phd. course

34
Bioinformatics PhD. Course Summary (approximate) 1. Biological introduction 2. Comparison of short sequences (<10.000 bps) 4 Sequence assembly 3 Comparison of large sequences (up to 250 000 000) 5 Efficient data search structures and algorithms 6 Proteins...

Upload: kateb

Post on 09-Jan-2016

53 views

Category:

Documents


4 download

DESCRIPTION

Bioinformatics PhD. Course. Summary (approximate). 1. Biological introduction. 2. Comparison of short sequences (

TRANSCRIPT

Page 1: Bioinformatics PhD. Course

Bioinformatics PhD. Course

Summary (approximate)

• 1. Biological introduction• 2. Comparison of short sequences (<10.000 bps)

• 4 Sequence assembly

• 3 Comparison of large sequences (up to 250 000 000)

• 5 Efficient data search structures and algorithms

• 6 Proteins...

Page 2: Bioinformatics PhD. Course

3. Comparison of large sequences

Summary (more or less)

• 3.1 Overview• 3.2 Suffix trees• 3.3 MUMs

Page 3: Bioinformatics PhD. Course

Sequence assembly

It has two applications:

• EST assembly: using mRNA fragments to find the genes expressed in a cell

• DNA sequencing: determining the bases of a DNA sequence.

Page 4: Bioinformatics PhD. Course

• Hybridization: allows the tuples of a given length in a sequence to be found.

DNA sequencing

Techniques employed:

• Shotgun: breaks a sequence into small pieces.

Page 5: Bioinformatics PhD. Course

• Hybridization: allows the tuples of a given length in a sequence to be found.

DNA sequencing

Techniques employed:

• Shotgun: breaks a sequence into small pieces.

Page 6: Bioinformatics PhD. Course

Hybridization

Imagine we want to determine the sequence xxxxxxxxxxxxx

and we know that it contains the following triplets:

AAC GAT TGCACG CGG GCC TTG GGA ATT

How can the sequence be established?

Page 7: Bioinformatics PhD. Course

Hybridization

We create a graph based on suffix-prefix overlaps

AAC GAT TGC

ACG CGG GCC TTG

GGA ATT

AACGGATTGCC

The sequence is deduced following the path in the graph

What is the cost of finding the path?

Page 8: Bioinformatics PhD. Course

Hybridization

Let us consider a more realistic case:

For a general case we find the Hamiltonian path (NP-Complet)

What is the cost of the entire hybridization technique?

AAC CAA GAT TGC

ACG CGG GCC TTG

GGC GGA CCG ATT

Page 9: Bioinformatics PhD. Course

Hybridization technique:

Cost: 1. Find the L-tuples AAC, CAA, ACG,... :

2. Find the overlaps AAC ACA,... :

All possible 4L tuples are constructed and searched

If there are m pieces of length L, then there are O(m2 L2 ) comparisons

3. Create the graph and find the Hamiltonian path

NP- Complet

Page 10: Bioinformatics PhD. Course

Note

Quadratic cost: O(m2 )

Linear cost: O(m)

Exponential cost: O(2m )

m t = 1 mseg10m 10t = 10 mseg1000m 1000t = 1 seg

m t = 1mseg.10m 100t = 100 mseg.1000m 1000000t = 16 min

m t = 1 mseg.10m 210 t = 1 seg1000m 21000 t = 1030 t = 1018 years

Page 11: Bioinformatics PhD. Course

Hybridization technique:

Cost: 1. Find the L-tuples AAC, CAA, ACG,... :

2. Find the overlaps AAC ACA,... :

All possible 4L tuples are constructed and searched

If there are m pieces of length L, then there are O(m2 L2 ) comparisons

3. Create the graph and find the Hamiltonian path

NP- Complet

How can we avoid NP-completeness?

Page 12: Bioinformatics PhD. Course

Hybridization: two reductions

Find the Hamiltonian path (NP-complete)

AAC GAT TGC

ACG CGG GCC TTG

GGC GGA CCG ATT

or find the Eulerian path (linear) AA

AC

GG

CG

GA

CC

GC

TG

TT

AT

Page 13: Bioinformatics PhD. Course

Hybridization: Eulerian path

Define unbalanced nodes: entry degree = exit degree(Starting or ending nodes: )

Define balanced nodes: entry degree = exit degree(traversal nodes: )

Finding the Eulerian path of a graph:

Page 14: Bioinformatics PhD. Course

Hybridization: Eulerian path

Algorithm: Create a random path from a starting node to an ending node Add circuits at balanced nodes

Page 15: Bioinformatics PhD. Course

Hybridization: camí Eulerià

Algorithm: Create a random path from a starting node to an ending node Add circuits at balanced nodes

Page 16: Bioinformatics PhD. Course

Hybridization technique:

Cost: 1. Find the L-tuples AAC, CAA, ACG,... :

2. Find the overlaps AAC ACA,... :

All possible 4L tuples are constructed and searched

If there are m pieces of length L, then there are O(m2 L2 ) comparisons

3. Create the graph and find the Eulerian path

Linear

What is the limiting factor?

Page 17: Bioinformatics PhD. Course

Hybridization: limitations of the technique

AAC CAA GAT TGC

ACG CGG GCC TTG

GGA ATT

Repeated fragments

What is the probability that a fragment repeats?

CAACGGATTGCC

CAACGGACGGATTGCC

GAC

Page 18: Bioinformatics PhD. Course

Hybridization

Model: random sequence of length N with an equally distribution (1/4),

We estimate the probability that a fragment repeats:

Given 2 fragments, the probability that they are identical: 4-L

Given 3 fragment, the probability that two of them are identical: (32)4-L

Given m fragment, the probability that two of them are identical: (m2)4-L

If L=8 and we want this probability to be 1%, then m =32

Conclusion: the technique of Hybridization can only be applied to short sequences.

Page 19: Bioinformatics PhD. Course

Excursió: hipòtesi d’equiprobabilitat

Cromosoma 21 té unes 34Mb distribuïdes:

A: 30% C: 20% G:20% T:20%

i si tenim en compte parells de bases, per exemple

AA: 10% AC: 5%

Fins a quin punt són equiprobables les seqüències?

Page 20: Bioinformatics PhD. Course
Page 21: Bioinformatics PhD. Course

Seqüenciació del DNA

De quines tècniques es disposa:

• Trets: permet disparar sobre la seqüència i trencar-la en trossos.

• Hybridization: permet saber quins mots d’una longitud fixa es troben a la seqüencia.

Page 22: Bioinformatics PhD. Course

Trets

Imaginem que volem conèixer la seqüència xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

i la nostra tècnica ens permet :

• copiar-la

• partir-la a l’atzar en trossos de diferent llargada i sense saber-ne l’ordre

Què podem fer?

Page 23: Bioinformatics PhD. Course

Trets: algorisme

Imaginem xxxxx|xxxxxxx|xxxxxxx|xxxx xxxxxxxx|xxxxxx|xxxxxx|xxxxxxx|xxxxxx|xxxxxx|xxxxxxx

L’algorisme serà:

1er. Comparar tots els trossos dos a dos per esbrinar com es superposen (eliminant inclusions).

2on. Construir el graf sufix-prefix

3er. Buscar el camí

Page 24: Bioinformatics PhD. Course

Trets

La copiem tres cops xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

n’obtenim els trossos

accgt, aggt, acgatac, accttta, tttaac, gataca, accgtacc, ggt, acaggt,taacgat, accg, tacctt

Page 25: Bioinformatics PhD. Course

Trets

Cal comparar els trossos per veure quins engalcen sufix-prefix

• Directament amb programació dinàmica (Cost quadràtic)

(tots contre tots i la majoria no engalceran)

• En dos passos:• Detectar els que engalcen

(Cost lineal amb l’Algorisme hash)

• Aplicar Prog. Dinàmica només als que engalcen

Page 26: Bioinformatics PhD. Course

Excursió: algorisme de hash

Page 27: Bioinformatics PhD. Course

Trets

accgtaccaccttta

tacctt

tttaac taacga

acgatac

accgaccgt

tacaggt

gataca

construïm el graf (cost quadràtic)

accgtacctttaacgatacaggt

i aconseguim la seqüència (cost exponencial)

Page 28: Bioinformatics PhD. Course

Trets: problemes

Problemes

xxxxxxxxxxxxx

xxxxx

xxxxxx xxxxxx xxxxxxxx

accgaccgt

xxxxxxxxxxxxxx

• Repeticions consecutives• Repeticions curtes llunyanes• Falta de recobriment (problemes al seqüenciar)• Errors en els trossos (problemes al seqüenciar)

Page 29: Bioinformatics PhD. Course

Trets: propietats del recobriment

Estudiem el recobriment:

Qüestions importants:

• Quina és la llargada mitja dels “contigs”?

• Quin es el nombre esperat de “contigs”?

• Quin és el percentatge de recobriment de la seqüència?

Page 30: Bioinformatics PhD. Course

Trets: percentatge de recobriment

Grau de cobertura de la seqüència N d / L

Quin és el percentatge de recobriment de la seqüència?L

N d

Suposem que els segments estan uniformament distribuïts.

que una base de la seqüència sigui recoberta per k segments ve donada per la Dist. Binomial (N,d / L):

La probabilitat de

Prob{X=k}= (d/L)k (1-d/L)n-kNk

Page 31: Bioinformatics PhD. Course

Excursió: distribució binomial

Distribució binomial B(n,p):

amb probabilitats p i 1-p de que hi caigui una bola.

Tenim dues urnes:

p 1-p

Quina és la probabilitat de que d’entre n boles en caiguin ka la primera urna?

Prob{X=k}= pk (1-p)n-knk

Page 32: Bioinformatics PhD. Course

Excursió: distribució de Poisson

Quin és el límit de la distribució binomial quan n i p 0

conservant-se constant el producte np=

Distribució de Poisson P()

Prob{X=k}= e- (demostració a classe)k

k!

Llavors la probabilitat de que almenys caigui una bola és

Prob{X>0}= 1-Prob{X=0}= 1- e-

Page 33: Bioinformatics PhD. Course

Trets: percentatge de recobriment

Si volem un recobriment del 99% cal que N d / L = 4.6

Distribució Binomial (N ,d / L)

Distribució de Poisson (N d / L)N d/L 0

Llavors el percentatge de recobriment ve donat per

la probabilitat de que al menys un tros cobreixi cada punt

1- e(N d / L)

Si volem un recobriment del 99.9% cal que N d / L = 6.9

Page 34: Bioinformatics PhD. Course

Engalçament d’EST

Tenim milers de trosso de unes 500 bases de longitud,que pertanyen a diferents

L’algorisme serà:

1er. Comparar tots els trossos dos a dos per esbrinar quins estan relacionats(eliminant inclusions).

2on. Construir el graf sufix-prefix: (surten molts petits grafs)

3er. Buscar el camí