Commit 186b5cc6 authored by Gerald Salin's avatar Gerald Salin
Browse files

#66 insert the component to align against a subset of the initial reads

parent 9b007cae
......@@ -35,6 +35,7 @@ class IlluminaQualityCheck (CasavaNG6Workflow):
def define_parameters(self, function="process"):
self.add_input_file("reference_genome", "Which genome should the read being align on")
self.add_parameter("delete_bam", "The BAM are not stored", type=bool, default = False)
self.add_parameter("align_subset_reads", "Align only on subset reads", type=bool, default = False)
self.add_parameter("histogram_width", "Explicitly sets the histogram width, overriding automatic truncation of histogram tail", type=int, default = 800, group="INSERTSIZE section")
self.add_parameter("min_pct", "When generating the histogram, discard any data categories (out of FR, TANDEM, RF) that have"+
" fewer than this percentage of overall reads", type=float, default = 0.01, group="INSERTSIZE section")
......@@ -55,7 +56,13 @@ class IlluminaQualityCheck (CasavaNG6Workflow):
sample_lane_prefixes = None
if self.group_prefix != None :
sample_lane_prefixes = list((Utils.get_group_basenames(filtered_read1_files+filtered_read2_files, "lane")).keys())
bwa = self.add_component("BWA", [indexed_ref, filtered_read1_files, filtered_read2_files, sample_lane_prefixes, "mem", not self.delete_bam], parent = fastqilluminafilter)
if self.align_subset_reads:
subset = self.add_component("SubsetSeqFiles", [filtered_read1_files, filtered_read2_files, self.align_subset_reads], parent = fastqilluminafilter)
filtered_read1_files = subset.subset_read1
filtered_read2_files = subset.subset_read2
bwa = self.add_component("BWA", [indexed_ref, filtered_read1_files, filtered_read2_files, sample_lane_prefixes, "mem", not self.delete_bam], parent = subset)
else:
bwa = self.add_component("BWA", [indexed_ref, filtered_read1_files, filtered_read2_files, sample_lane_prefixes, "mem", not self.delete_bam], parent = fastqilluminafilter)
# make some statistic on the alignement
alignmentstats = self.add_component("AlignmentStats", [bwa.bam_files, self.is_paired_end(), False], parent = bwa)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment