vdj_pipe
pipeline for processing DNA sequence data
quality_stats_step.hpp
Go to the documentation of this file.
1 
7 #ifndef QUALITY_STATS_STEP_HPP_
8 #define QUALITY_STATS_STEP_HPP_
9 #include <iosfwd>
10 #include <string>
11 #if defined(NDEBUG)
12 //fix boost::multi_array warnings
13 //boost/multi_array/base.hpp:503:13: warning: unused variable 'bound_adjustment'
14 #define BOOST_DISABLE_ASSERTS
15 #endif
16 #include "boost/array.hpp"
17 #include "boost/multi_array.hpp"
18 #include "boost/property_tree/ptree_fwd.hpp"
19 #include "vdj_pipe/config.hpp"
21 #include "vdj_pipe/file.hpp"
24 
25 namespace vdj_pipe{
26 
31 
32  typedef boost::array<double,5> fractions;
33  static fractions const& fracts() {
34  static const fractions f = {{0.1, 0.25, 0.5, 0.75, 0.9}};
35  return f;
36  }
37 
38 public:
39  VDJ_PIPE_STATIC_STRING_METHOD(name, "quality_stats")
40  VDJ_PIPE_STATIC_STRING_METHOD(category, "statistics")
42  comment,
43  "calculate quality statistics of sequencing reads"
44  )
45 
47  description,
48  "based on trimmed reads"
49  )
50 
51  Qual_stats(
52  Vm_access_single const& vma,
55  );
56 
57  void run();
58  void finish();
59 
60 private:
61  heat_map hm_;
64  std::string out_hm_;
65  std::string out_qs_;
66  std::string out_mqh_;
67  std::string out_len_hist_;
68 
69  void write_heat_map() const;
70  void write_qstats() const;
71  void write_meanq_hist() const;
72  void write_len_hist() const;
73 };
74 
75 }//namespace vdj_pipe
76 #endif /* QUALITY_STATS_STEP_HPP_ */
Definition: quality_stats_step.hpp:29
Histogram_1d lh_
Definition: quality_stats_step.hpp:63
boost::multi_array< std::size_t, 2 > heat_map
Definition: quality_stats_step.hpp:30
std::string out_hm_
Definition: quality_stats_step.hpp:64
Definition: value_map_access_single.hpp:16
Main namespace of vdj_pipe library.
Definition: keywords_variable.hpp:11
Definition: pipe_environment.hpp:26
Histogram_1d mqh_
Definition: quality_stats_step.hpp:62
#define VDJ_PIPE_DECL
Definition: config.hpp:23
std::string out_qs_
Definition: quality_stats_step.hpp:65
static fractions const & fracts()
Definition: quality_stats_step.hpp:33
std::string out_len_hist_
Definition: quality_stats_step.hpp:67
#define VDJ_PIPE_STATIC_STRING_METHOD(name, val)
Definition: keyword_struct_macro.hpp:12
std::string out_mqh_
Definition: quality_stats_step.hpp:66
heat_map hm_
Definition: quality_stats_step.hpp:61
Definition: step_base_single.hpp:16
simple unsigned integer-based histogram
Definition: histogram_1d.hpp:17
bpt::ptree ptree
Definition: processing_step_utils.hpp:19
boost::array< double, 5 > fractions
Definition: quality_stats_step.hpp:32