comparison BEDTools-Version-2.14.3/src/pairToPair/pairToPair.h @ 0:dfcd8b6c1bda

Uploaded
author aaronquinlan
date Thu, 03 Nov 2011 10:25:04 -0400
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:dfcd8b6c1bda
1 /*****************************************************************************
2 pairToPair.h
3
4 (c) 2009 - Aaron Quinlan
5 Hall Laboratory
6 Department of Biochemistry and Molecular Genetics
7 University of Virginia
8 aaronquinlan@gmail.com
9
10 Licenced under the GNU General Public License 2.0 license.
11 ******************************************************************************/
12 #ifndef PAIRTOPAIR_H
13 #define PAIRTOPAIR_H
14
15 #include "bedFile.h"
16 #include "bedFilePE.h"
17 #include <vector>
18 #include <iostream>
19 #include <fstream>
20
21 using namespace std;
22
23
24
25 //************************************************
26 // Class methods and elements
27 //************************************************
28 class PairToPair {
29
30 public:
31
32 // constructor
33 PairToPair(string &bedAFilePE, string &bedBFilePE, float &overlapFraction,
34 string searchType, bool ignoreStrand, bool reqDiffNames, int slop, bool strandedSlop);
35
36 // destructor
37 ~PairToPair(void);
38
39 void IntersectPairs();
40
41
42 private:
43
44 string _bedAFilePE;
45 string _bedBFilePE;
46
47 float _overlapFraction;
48 string _searchType;
49 bool _ignoreStrand;
50 bool _reqDiffNames;
51 int _slop;
52 bool _strandedSlop;
53
54 // instance of a paired-end bed file class.
55 BedFilePE *_bedA;
56
57 // instance of a bed file class.
58 BedFilePE *_bedB;
59
60 // methods
61 // void FindOverlaps(const BEDPE &a, vector<MATE> &hitsA1B1, vector<MATE> &hitsA1B2,
62 // vector<MATE> &hitsA2B1, vector<MATE> &hitsA2B2);
63 void FindOverlaps(const BEDPE &a);
64
65 void FindQualityHitsBetweenEnds(CHRPOS start, CHRPOS end,
66 const vector<MATE> &hits, vector<MATE> &qualityHits, int &numOverlaps);
67
68 bool FindHitsOnBothEnds(const BEDPE &a, const vector<MATE> &qualityHitsEnd1,
69 const vector<MATE> &qualityHitsEnd2);
70
71 void FindHitsOnEitherEnd(const BEDPE &a, const vector<MATE> &qualityHitsEnd1,
72 const vector<MATE> &qualityHitsEnd2);
73
74 };
75
76 #endif /* PAIRTOPAIR_H */