Skip to content

Commit 5649575

Browse files
committed
Corrected lingering references to phased_read.is_phased to is_tagged.
1 parent 75e649f commit 5649575

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

src/HaplotagLR/cli.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ def haplotag(args):
138138
# can be processed immediately. If not using the negative binomial error model,
139139
# we can process phased reads now too. For the negative-binomial error model, we
140140
# need to store all phased reads for later processing/relabeling/filtering.
141-
if args.FDR_threshold <= 0 or not phased_read.is_phased:
141+
if args.FDR_threshold <= 0 or not phased_read.is_tagged:
142142
write_bam_output(phased_read, output_streams, args)
143143
else:
144144
# Read is phased and we are using the negative-binomial haplotag error model.
@@ -277,7 +277,7 @@ def write_phase_tagged_bam_output(phased_read, phased_output_bam,
277277
reads written to their own files.
278278
279279
"""
280-
if phased_read.is_phased:
280+
if phased_read.is_tagged:
281281
if (args.log_likelihood_threshold >= 0 and phased_read.log_likelihood_ratio >= args.log_likelihood_threshold) or phased_read.haplotag_error_rate <= args.error_rate_threshold:
282282
# Phased read passing the error-rate/score threshold.
283283
phased_read.write_to_bam(output_bam_pysam = phased_output_bam)
@@ -298,7 +298,7 @@ def write_full_bam_output(phased_read, maternal_output_bam, paternal_output_bam,
298298
unphased and nonphasable reads written to their own files.
299299
"""
300300
# TO-DO: Need to handle all possible levels of ploidy.
301-
if phased_read.is_phased:
301+
if phased_read.is_tagged:
302302
if (args.log_likelihood_threshold >= 0 and phased_read.log_likelihood_ratio >= args.log_likelihood_threshold) or phased_read.haplotag_error_rate <= args.error_rate_threshold:
303303
if phased_read.phase == 1:
304304
phased_read.write_to_bam(output_bam_pysam = paternal_output_bam)

0 commit comments

Comments
 (0)