nodes: 0, module; 1, function_definition; 2, function_name:report; 3, parameters; 4, block; 5, identifier:self; 6, identifier:align_bam; 7, identifier:ref_file; 8, identifier:gtf_file; 9, default_parameter; 10, default_parameter; 11, expression_statement; 12, comment:# collect duplication metrics; 13, expression_statement; 14, expression_statement; 15, expression_statement; 16, if_statement; 17, expression_statement; 18, expression_statement; 19, expression_statement; 20, if_statement; 21, return_statement; 22, identifier:is_paired; 23, False; 24, identifier:rrna_file; 25, string:"null"; 26, comment:"""Produce report metrics for a RNASeq experiment using Picard
          with a sorted aligned BAM file.
  
          """; 27, assignment; 28, assignment; 29, assignment; 30, identifier:is_paired; 31, block; 32, assignment; 33, assignment; 34, assignment; 35, boolean_operator; 36, block; 37, expression_list; 38, identifier:dup_metrics; 39, call; 40, identifier:align_metrics; 41, call; 42, pattern_list; 43, tuple; 44, expression_statement; 45, identifier:rnaseq_metrics; 46, call; 47, identifier:summary_info; 48, call; 49, identifier:graphs; 50, list; 51, identifier:insert_graph; 52, call; 53, expression_statement; 54, identifier:summary_info; 55, identifier:graphs; 56, attribute; 57, argument_list; 58, attribute; 59, argument_list; 60, identifier:insert_graph; 61, identifier:insert_metrics; 62, None; 63, None; 64, assignment; 65, attribute; 66, argument_list; 67, attribute; 68, argument_list; 69, identifier:file_exists; 70, argument_list; 71, call; 72, identifier:self; 73, identifier:_get_current_dup_metrics; 74, identifier:align_bam; 75, identifier:self; 76, identifier:_collect_align_metrics; 77, identifier:align_bam; 78, identifier:ref_file; 79, pattern_list; 80, call; 81, identifier:self; 82, identifier:_rnaseq_metrics; 83, identifier:align_bam; 84, identifier:gtf_file; 85, identifier:rrna_file; 86, attribute; 87, identifier:get_summary_metrics; 88, identifier:align_metrics; 89, identifier:dup_metrics; 90, keyword_argument; 91, keyword_argument; 92, identifier:insert_graph; 93, attribute; 94, argument_list; 95, identifier:insert_graph; 96, identifier:insert_metrics; 97, attribute; 98, argument_list; 99, identifier:self; 100, identifier:_parser; 101, identifier:insert_metrics; 102, identifier:insert_metrics; 103, identifier:rnaseq_metrics; 104, identifier:rnaseq_metrics; 105, identifier:graphs; 106, identifier:append; 107, tuple; 108, identifier:self; 109, identifier:_insert_sizes; 110, identifier:align_bam; 111, identifier:insert_graph; 112, string:"Distribution of paired end insert sizes"
code: def report(self, align_bam, ref_file, gtf_file, is_paired=False, rrna_file="null"):
          """Produce report metrics for a RNASeq experiment using Picard
          with a sorted aligned BAM file.
  
          """
  
          # collect duplication metrics
          dup_metrics = self._get_current_dup_metrics(align_bam)
          align_metrics = self._collect_align_metrics(align_bam, ref_file)
          insert_graph, insert_metrics = (None, None)
          if is_paired:
              insert_graph, insert_metrics = self._insert_sizes(align_bam)
  
          rnaseq_metrics = self._rnaseq_metrics(align_bam, gtf_file, rrna_file)
  
          summary_info = self._parser.get_summary_metrics(align_metrics,
                                                  dup_metrics,
                                                  insert_metrics=insert_metrics,
                                                  rnaseq_metrics=rnaseq_metrics)
          graphs = []
          if insert_graph and file_exists(insert_graph):
              graphs.append((insert_graph,
                             "Distribution of paired end insert sizes"))
          return summary_info, graphs