From 4c2f9d0573abf7eda6e9045fa0e7b443b75e1297 Mon Sep 17 00:00:00 2001 From: Nils Homer Date: Sun, 20 Feb 2022 14:35:15 -0700 Subject: [PATCH 1/3] Change default sort orders of consensus callers This affects CallDuplexConsensusReads and CallMolecularConsensusReads. When no sort order is given, the output is unsorted but query-grouped, which is sufficient for either downstream re-alignment or consensus filtering. We can thus avoid sorting the output consensus reads when calling. --- .../com/fulcrumgenomics/umi/CallDuplexConsensusReads.scala | 2 +- .../com/fulcrumgenomics/umi/CallMolecularConsensusReads.scala | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/scala/com/fulcrumgenomics/umi/CallDuplexConsensusReads.scala b/src/main/scala/com/fulcrumgenomics/umi/CallDuplexConsensusReads.scala index 3e7d8b01e..d7883c3e3 100644 --- a/src/main/scala/com/fulcrumgenomics/umi/CallDuplexConsensusReads.scala +++ b/src/main/scala/com/fulcrumgenomics/umi/CallDuplexConsensusReads.scala @@ -98,7 +98,7 @@ class CallDuplexConsensusReads @arg(flag='2', doc="The Phred-scaled error rate for an error post the UMIs have been integrated.") val errorRatePostUmi: PhredScore = DefaultErrorRatePostUmi, @arg(flag='m', doc="Ignore bases in raw reads that have Q below this value.") val minInputBaseQuality: PhredScore = DefaultMinInputBaseQuality, @arg(flag='t', doc="If true, quality trim input reads in addition to masking low Q bases.") val trim: Boolean = false, - @arg(flag='S', doc="The sort order of the output, if `:none:` then the same as the input.") val sortOrder: Option[SamOrder] = Some(SamOrder.Queryname), + @arg(flag='S', doc="The sort order of the output, if `:none:` then the same as the input.") val sortOrder: Option[SamOrder] = None, @arg(flag='M', minElements=1, maxElements=3, doc="The minimum number of input reads to a consensus read.") val minReads: Seq[Int] = Seq(1), @arg(doc=""" |The maximum number of reads to use when building a single-strand consensus. If more than this many reads are diff --git a/src/main/scala/com/fulcrumgenomics/umi/CallMolecularConsensusReads.scala b/src/main/scala/com/fulcrumgenomics/umi/CallMolecularConsensusReads.scala index 44b3cefe3..4a9bfc610 100644 --- a/src/main/scala/com/fulcrumgenomics/umi/CallMolecularConsensusReads.scala +++ b/src/main/scala/com/fulcrumgenomics/umi/CallMolecularConsensusReads.scala @@ -121,7 +121,7 @@ class CallMolecularConsensusReads """) val maxReads: Option[Int] = None, @arg(flag='B', doc="If true produce tags on consensus reads that contain per-base information.") val outputPerBaseTags: Boolean = DefaultProducePerBaseTags, - @arg(flag='S', doc="The sort order of the output, if `:none:` then the same as the input.") val sortOrder: Option[SamOrder] = Some(SamOrder.Queryname), + @arg(flag='S', doc="The sort order of the output, if `:none:` then the same as the input.") val sortOrder: Option[SamOrder] = None, @arg(flag='D', doc="Turn on debug logging.") val debug: Boolean = false, @arg(doc="The number of threads to use while consensus calling.") val threads: Int = 1 ) extends FgBioTool with LazyLogging { From 773842ad64000f285eb5ec11da49e3b371b66561 Mon Sep 17 00:00:00 2001 From: Nils Homer Date: Sat, 26 Feb 2022 08:15:25 -0700 Subject: [PATCH 2/3] Update src/main/scala/com/fulcrumgenomics/umi/CallDuplexConsensusReads.scala --- .../com/fulcrumgenomics/umi/CallDuplexConsensusReads.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/scala/com/fulcrumgenomics/umi/CallDuplexConsensusReads.scala b/src/main/scala/com/fulcrumgenomics/umi/CallDuplexConsensusReads.scala index d7883c3e3..7b8cd2518 100644 --- a/src/main/scala/com/fulcrumgenomics/umi/CallDuplexConsensusReads.scala +++ b/src/main/scala/com/fulcrumgenomics/umi/CallDuplexConsensusReads.scala @@ -98,7 +98,7 @@ class CallDuplexConsensusReads @arg(flag='2', doc="The Phred-scaled error rate for an error post the UMIs have been integrated.") val errorRatePostUmi: PhredScore = DefaultErrorRatePostUmi, @arg(flag='m', doc="Ignore bases in raw reads that have Q below this value.") val minInputBaseQuality: PhredScore = DefaultMinInputBaseQuality, @arg(flag='t', doc="If true, quality trim input reads in addition to masking low Q bases.") val trim: Boolean = false, - @arg(flag='S', doc="The sort order of the output, if `:none:` then the same as the input.") val sortOrder: Option[SamOrder] = None, + @arg(flag='S', doc="The sort order of the output, the same as the input if not given.") val sortOrder: Option[SamOrder] = None, @arg(flag='M', minElements=1, maxElements=3, doc="The minimum number of input reads to a consensus read.") val minReads: Seq[Int] = Seq(1), @arg(doc=""" |The maximum number of reads to use when building a single-strand consensus. If more than this many reads are From c2a3c57c67dc0f205e7672ba5bbea9f390cb50af Mon Sep 17 00:00:00 2001 From: Nils Homer Date: Sat, 26 Feb 2022 08:15:29 -0700 Subject: [PATCH 3/3] Update src/main/scala/com/fulcrumgenomics/umi/CallMolecularConsensusReads.scala --- .../com/fulcrumgenomics/umi/CallMolecularConsensusReads.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/scala/com/fulcrumgenomics/umi/CallMolecularConsensusReads.scala b/src/main/scala/com/fulcrumgenomics/umi/CallMolecularConsensusReads.scala index 4a9bfc610..f14644d82 100644 --- a/src/main/scala/com/fulcrumgenomics/umi/CallMolecularConsensusReads.scala +++ b/src/main/scala/com/fulcrumgenomics/umi/CallMolecularConsensusReads.scala @@ -121,7 +121,7 @@ class CallMolecularConsensusReads """) val maxReads: Option[Int] = None, @arg(flag='B', doc="If true produce tags on consensus reads that contain per-base information.") val outputPerBaseTags: Boolean = DefaultProducePerBaseTags, - @arg(flag='S', doc="The sort order of the output, if `:none:` then the same as the input.") val sortOrder: Option[SamOrder] = None, + @arg(flag='S', doc="The sort order of the output, the same as the input if not given.") val sortOrder: Option[SamOrder] = None, @arg(flag='D', doc="Turn on debug logging.") val debug: Boolean = false, @arg(doc="The number of threads to use while consensus calling.") val threads: Int = 1 ) extends FgBioTool with LazyLogging {