origincomment
Class Matrice_ALN

java.lang.Object
  extended by origincomment.Matrice_ALN

public class Matrice_ALN
extends java.lang.Object

Alignment matrix...

Author:
Stéfan Engelen (2006) for coding..., Gabriel Chandesris (2008) for comments and makeing the code readable.
See Also:
Case

Field Summary
private  ADN1test adncible
          Target sequence in format of test sequence.
private  java.util.Vector alignements
          Vector of alignments.
private  int[] courant
          A current tab of integers.
private static double lmin
          Lmin / minimal length.
private  Case[][] matrice
          2D table (default is null).
private static double[] meilleurScore
          Best score matrix.
private  int nb_alignements
          Number of alignments.
private  int nb_alignements_trouves
          Number of alignments found.
private  int[] position3prime
          "bases postions of palindrome in test sequence" 3' side
private  int[] position5prime
          "bases postions of palindrome in test sequence" 5' side
private  java.lang.String seq3prime
          3' sequence (default is empty ("")).
private  java.lang.String seq5prime
          5' sequence (default is empty ("")).
private static int taille3prime
          Length on 3' side.
private static int taille5prime
          Length on 5' side.
 
Constructor Summary
Matrice_ALN(ADN1test seqcible, ADN1test seqtest, int debut5, int fin5, int debut3, int fin3, int nbaln, double lgmin)
           
 
Method Summary
private  void aligner()
          Local alignment (Smith and Waterman).
private static double[] calcul_score(int[] quelAln, Matrice_ALN[] tabMat)
          Score computing ?
static void change_meilleur_score(double[] nvscore, boolean forcage)
          To set the best scores.
private  void chercher_meilleur()
          Searching the best...
private static void choisi_aln(int[] quelAln, Matrice_ALN[] tabMat, int etape)
          Alignment choice ?
private static void choisi_seq(Matrice_ALN[] tabMat, int[] quelleSeq, int etape, int debut)
          Sequence choice ?
private  void initialiser()
          Initialization of scoring matrix with new Cases, height and width +1 more than sequences.
static double meilleur_score(int i)
           
private  boolean meilleur()
          To get the best ??
static void meilleure_combinaison(Matrice_ALN[] tabMat, int nbSeqTest, int typeRecherche)
          Best combination ?
 int quel_nombre_aln()
           
 Case quelle_case()
           
 Case quelle_case(int i, int j)
           
 java.lang.String quelle_seq_3prime()
           
 java.lang.String quelle_seq_5prime()
           
 java.util.Vector quels_alignements()
           
private  void recupere_alignement(Alignement align, int[] courant, int forcage)
          To gain the alignment ?
private  int[] score(char x, char y)
          Scoring a pairwise...
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

taille5prime

private static int taille5prime
Length on 5' side.


taille3prime

private static int taille3prime
Length on 3' side.


meilleurScore

private static double[] meilleurScore
Best score matrix. (default : {-100,-100,-100,-100,-100})
"{score,double mutation,error,relevance,single mutation}"
"{score,mutation double,erreur,pertinence,mutation simple}"


lmin

private static double lmin
Lmin / minimal length.


nb_alignements

private int nb_alignements
Number of alignments.


matrice

private Case[][] matrice
2D table (default is null).


courant

private int[] courant
A current tab of integers. (default has two columns).


seq5prime

private java.lang.String seq5prime
5' sequence (default is empty ("")).


seq3prime

private java.lang.String seq3prime
3' sequence (default is empty ("")).


position5prime

private int[] position5prime
"bases postions of palindrome in test sequence" 5' side


position3prime

private int[] position3prime
"bases postions of palindrome in test sequence" 3' side


alignements

private java.util.Vector alignements
Vector of alignments.


nb_alignements_trouves

private int nb_alignements_trouves
Number of alignments found.


adncible

private ADN1test adncible
Target sequence in format of test sequence.

Constructor Detail

Matrice_ALN

public Matrice_ALN(ADN1test seqcible,
                   ADN1test seqtest,
                   int debut5,
                   int fin5,
                   int debut3,
                   int fin3,
                   int nbaln,
                   double lgmin)
Parameters:
seqcible - (ADN1test) target sequence
seqtest - (ADN1test) test sequence
debut5 - (int) begining of palindrome
fin5 - (int) (begin+length-) of palindrome
debut3 - (int) end of palindrome
fin3 - (int) (end-length+1) of palindrome
nbaln - (int) number of alignment (1?)
lgmin - (double) lmin [unused]
See Also:
TestAln.main(String[]), ADN1cible.verifier_Conservation_Alignement(Palindrome1cible, Palindrome1test, double, ADN1test[]), initialiser(), aligner(), chercher_meilleur()
Method Detail

quelle_seq_5prime

public java.lang.String quelle_seq_5prime()

quelle_seq_3prime

public java.lang.String quelle_seq_3prime()

quelle_case

public Case quelle_case()

quelle_case

public Case quelle_case(int i,
                        int j)

quel_nombre_aln

public int quel_nombre_aln()

quels_alignements

public java.util.Vector quels_alignements()

meilleur_score

public static double meilleur_score(int i)

change_meilleur_score

public static void change_meilleur_score(double[] nvscore,
                                         boolean forcage)
To set the best scores.

Parameters:
nvscore - (double[])
forcage - (boolean) true to be sure to change, else check if first score is better to set.
See Also:
choisi_aln(int[], Matrice_ALN[], int), ADN1cible.verifier_Conservation_Alignement(Palindrome1cible, Palindrome1test, double, ADN1test[])

initialiser

private void initialiser()
Initialization of scoring matrix with new Cases, height and width +1 more than sequences.

See Also:
Matrice_ALN(ADN1test, ADN1test, int, int, int, int, int, double)

aligner

private void aligner()
Local alignment (Smith and Waterman).

See Also:
Matrice_ALN(ADN1test, ADN1test, int, int, int, int, int, double)

score

private int[] score(char x,
                    char y)
Scoring a pairwise...

Parameters:
x - (char)
y - (char)
Returns:
(int[]) 3 integers : {score, operation, normal score}
See Also:
aligner(), ADN1cible.score(char, char)

chercher_meilleur

private void chercher_meilleur()
Searching the best...

See Also:
Matrice_ALN(ADN1test, ADN1test, int, int, int, int, int, double), recupere_alignement(Alignement, int[], int), meilleur()

recupere_alignement

private void recupere_alignement(Alignement align,
                                 int[] courant,
                                 int forcage)
To gain the alignment ? Changes the alignment and mutations of current matrix instance.

Parameters:
align - (Alignement)
courant - (int[])
forcage - (int) operation
See Also:
chercher_meilleur()

meilleur

private boolean meilleur()
To get the best ??

Returns:
(boolean)
See Also:
chercher_meilleur()

meilleure_combinaison

public static void meilleure_combinaison(Matrice_ALN[] tabMat,
                                         int nbSeqTest,
                                         int typeRecherche)
Best combination ?

Parameters:
tabMat - (Matrice_ALN[])
nbSeqTest - (int)
typeRecherche - (typoeRecherche)
See Also:
ADN1cible.verifier_Conservation_Alignement(Palindrome1cible, Palindrome1test, double, ADN1test[])

choisi_aln

private static void choisi_aln(int[] quelAln,
                               Matrice_ALN[] tabMat,
                               int etape)
Alignment choice ?

Parameters:
quelAln - (int[])
tabMat - (Matrice_ALN[])
etape - (int) step
See Also:
meilleure_combinaison(Matrice_ALN[], int, int), choisi_seq(Matrice_ALN[], int[], int, int), change_meilleur_score(double[], boolean)

choisi_seq

private static void choisi_seq(Matrice_ALN[] tabMat,
                               int[] quelleSeq,
                               int etape,
                               int debut)
Sequence choice ?

Parameters:
tabMat - (Matrice_ALN[])
quelleSeq - (int[])
etape - (int) step
debut - (int) begin
See Also:
meilleure_combinaison(Matrice_ALN[], int, int)

calcul_score

private static double[] calcul_score(int[] quelAln,
                                     Matrice_ALN[] tabMat)
Score computing ?

Parameters:
quelAln - (int[])
tabMat - (Matrice_ALN[])
Returns:
(double[]) "{score,mutationDouble,erreur,pertinence,mutationSimple}"
See Also:
choisi_aln(int[], Matrice_ALN[], int)

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object