Mercurial > repos > aaronquinlan > multi_intersect
comparison BEDTools-Version-2.14.3/src/flankBed/flankBed.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 flankBed.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 | |
| 13 #include "bedFile.h" | |
| 14 #include "genomeFile.h" | |
| 15 | |
| 16 #include <vector> | |
| 17 #include <iostream> | |
| 18 #include <fstream> | |
| 19 #include <map> | |
| 20 #include <cstdlib> | |
| 21 #include <ctime> | |
| 22 using namespace std; | |
| 23 | |
| 24 | |
| 25 //************************************************ | |
| 26 // Class methods and elements | |
| 27 //************************************************ | |
| 28 class BedFlank { | |
| 29 | |
| 30 public: | |
| 31 | |
| 32 // constructor | |
| 33 BedFlank(string &bedFile, string &genomeFile, bool forceStrand, float leftSlop, float rightSlop, bool fractional); | |
| 34 | |
| 35 // destructor | |
| 36 ~BedFlank(void); | |
| 37 | |
| 38 | |
| 39 | |
| 40 private: | |
| 41 | |
| 42 string _bedFile; | |
| 43 string _genomeFile; | |
| 44 | |
| 45 bool _forceStrand; | |
| 46 float _leftFlank; | |
| 47 float _rightFlank; | |
| 48 bool _fractional; | |
| 49 | |
| 50 BedFile *_bed; | |
| 51 GenomeFile *_genome; | |
| 52 | |
| 53 // methods | |
| 54 | |
| 55 void FlankBed(); | |
| 56 | |
| 57 // method to grab requested flank w.r.t. a single BED entry | |
| 58 void AddFlank(BED &bed, int leftSlop, int rightSlop); | |
| 59 | |
| 60 // method to grab requested flank w.r.t. a single BED entry, | |
| 61 // while choosing flanks based on strand | |
| 62 void AddStrandedFlank(BED &bed, int leftSlop, int rightSlop); | |
| 63 }; |
