File tree Expand file tree Collapse file tree 1 file changed +30
-0
lines changed
Expand file tree Collapse file tree 1 file changed +30
-0
lines changed Original file line number Diff line number Diff line change 2323#include < string>
2424#include < random>
2525
26+ #include " sam_record.hpp"
27+
28+ namespace bsflags {
29+ // ADS: this is our addition to the SAM flags, using the "free" bits
30+ /* 4096 0x1000 read is A-rich
31+ */
32+ static const uint16_t read_is_t_rich = 0x1000 ;
33+ }
34+
35+ inline bool
36+ is_t_rich (const sam_rec &sr) {
37+ return samflags::check (sr.flags , bsflags::read_is_t_rich);
38+ }
39+
40+ inline bool
41+ is_a_rich (const sam_rec &sr) {
42+ return !samflags::check (sr.flags , bsflags::read_is_t_rich);
43+ }
44+
45+ inline void
46+ set_t_rich (sam_rec &sr) {
47+ samflags::set (sr.flags , bsflags::read_is_t_rich);
48+ }
49+
50+ inline void
51+ set_a_rich (sam_rec &sr) {
52+ samflags::unset (sr.flags , bsflags::read_is_t_rich);
53+ }
54+
55+
2656void
2757bisulfite_treatment (std::mt19937 &generator, std::string &seq,
2858 double bs_rate = 1.0 , double meth_rate = 0.0 );
You can’t perform that action at this time.
0 commit comments