helper.h

Go to the documentation of this file.
00001 #ifndef HELPER_H
00002 #define HELPER_H
00003 // helper functions for sequence alignments
00004 
00005 #include "seqaln.h"
00006 
00007 /* convert integer code to char with the fomular
00008  * int + 'A'
00009  */
00010 void code2seq(struct SEQALN_SEQUENCE *seq);
00011 /* non-matrix based comparison 
00012  * return match and mismatch scores repectively, depnding
00013  * on the a == b or not*/
00014 int delta(char a, char b, struct SEQALN_CONSTANTS *scoring);
00015 /* for matrix look up
00016  * use a<<5 + b to find the element faster
00017  * each row has 32 elements, this is faster
00018  */
00019 int mdelta(char a, char b, struct SEQALN_CONSTANTS *scoring);
00020 int pdelta(int a, char b, struct SEQALN_PROFILE *pro);
00021 int gap(int k, struct SEQALN_CONSTANTS *scoring);
00022 int pgap(int k, struct SEQALN_PROFILE *pro);
00023 int revcomp(struct SEQALN_SEQUENCE *seq);
00024 int revseq(struct SEQALN_SEQUENCE *seq);
00025 int compseq(struct SEQALN_SEQUENCE *seq);
00026 void rpt_version(char *prog, struct SEQALN_IO *io);
00027 void reverse_list(SEQALN_TRACE **list);
00028 void memfree(struct SEQALN_SEQUENCE *seq1, struct SEQALN_SEQUENCE *seq2, 
00029                  struct SEQALN_CONSTANTS *scoring, struct SEQALN_RESULTS *results,
00030                 struct SEQALN_IO *io);
00031 /*
00032    Header file for codon to protein translation, from the USC sequence
00033    alignment library.
00034    Paul Hardy, USC, November 1996
00035 */
00036 //char nuc2prot[64]={ /* AAA */  'K', /* AAC */  'N', /* AAG */  'K',
00037 //     /* AAU */  'N', /* ACA */  'T', /* ACC */  'T', /* ACG */  'T',
00038 //     /* ACU */  'T', /* AGA */  'R', /* AGC */  'S', /* AGG */  'R',
00039 //     /* AGU */  'S', /* AUA */  'I', /* AUC */  'I', /* AUG */  'M',
00040 //     /* AUU */  'I', /* CAA */  'Q', /* CAC */  'H', /* CAG */  'Q',
00041 //     /* CAU */  'H', /* CCA */  'P', /* CCC */  'P', /* CCG */  'P',
00042 //     /* CCU */  'P', /* CGA */  'R', /* CGC */  'R', /* CGG */  'R',
00043 //     /* CGU */  'R', /* CUA */  'L', /* CUC */  'L', /* CUG */  'L',
00044 //     /* CUU */  'L', /* GAA */  'E', /* GAC */  'D', /* GAG */  'E',
00045 //     /* GAU */  'D', /* GCA */  'A', /* GCC */  'A', /* GCG */  'A',
00046 //     /* GCU */  'A', /* GGA */  'G', /* GGC */  'G', /* GGG */  'G',
00047 //     /* GGU */  'G', /* GUA */  'V', /* GUC */  'V', /* GUG */  'V',
00048 //     /* GUU */  'V', /* UAA */  '*', /* UAC */  'Y', /* UAG */  '*',
00049 //     /* UAU */  'Y', /* UCA */  'S', /* UCC */  'S', /* UCG */  'S',
00050 //     /* UCU */  'S', /* UGA */  '*', /* UGC */  'C', /* UGG */  'W',
00051 //     /* UGU */  'C', /* UUA */  'L', /* UUC */  'F', /* UUG */  'L',
00052 //     /* UUU */  'F'};
00053 int xlate(struct SEQALN_SEQUENCE *seq);
00054 void freeTraceList(struct SEQALN_RESULTS *rslt);
00055 #endif

Generated on Wed Aug 10 11:56:53 2011 for Softwares from Orpara by  doxygen 1.5.6