ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/gclib/tophat_cpp/align_status.h
Revision: 154
Committed: Tue Jan 24 02:29:21 2012 UTC (12 years, 7 months ago) by gpertea
File size: 1321 byte(s)
Log Message:
massive update with Daehwan's work

Line File contents
1 #ifndef ALIGN_STATUS_H
2 #define ALIGN_STATUS_H
3
4 #ifdef HAVE_CONFIG_H
5 #include <config.h>
6 #endif
7
8 #include <stdint.h>
9 #include <stdio.h>
10 #include <stdlib.h>
11 #include <string>
12 #include <map>
13 #include <vector>
14 #include <cassert>
15 #include <cstring>
16 #include <seqan/sequence.h>
17 #include <bam/sam.h>
18 #include "common.h"
19 #include "junctions.h"
20
21
22 using namespace std;
23
24
25 /**
26 * The main purpose of this struct is to provide a
27 * (fairly primitive) method for ranking competing alignments
28 * for a read. In general,
29 * continguous > spliced > in/dels = fusions
30 * Ties are broken with the number of mismatches
31 */
32 struct AlignStatus
33 {
34
35
36 private:
37 /**
38 * Is this alignment free of indels. Note, if there is no alignment
39 * this should still be false.
40 */
41 bool _indelFreeAlignment;
42
43 /**
44 * Is this alignment free of unannotated splices? Note, if there is no alignment
45 * this should still be false
46 */
47 bool _unannotatedSpliceFreeAlignment;
48
49 bool _fusionFreeAlignment;
50
51 /**
52 * Is there an alignment?
53 */
54 bool _aligned;
55 unsigned char _edit_dist;
56 public:
57 AlignStatus();
58 AlignStatus(const BowtieHit& bh, const JunctionSet& gtf_junctions);
59
60 bool operator<(const AlignStatus& rhs) const;
61 bool operator==(const AlignStatus& rhs) const;
62 bool operator!=(const AlignStatus& rhs) const;
63 };
64
65 #endif