magicDGS / ReadTools

A Universal Toolkit for Handling Sequence Data from Different Sequencing Platforms
https://magicdgs.github.io/ReadTools/
MIT License
6 stars 3 forks source link

Decide cli-management for integer-tag counter arguments #449

Open magicDGS opened 6 years ago

magicDGS commented 6 years ago

After #446, there are two classes for the same statistic: PairIntegerTagCounter and PairIntegerTagListCounter, which is not ideal and it is error prone for the cli-user (once integrated with the tool in #437 and #448). There are different ways to solve this to go out of experimental/beta:

  1. Remove completely PairIntegerTagListCounter in favor of a way to include in barclay plugins several instances from the same class (see https://github.com/broadinstitute/barclay/issues/138).
  2. Remove completely the PairIntegerTagCounter in favor of the list-stat, and implement every stat that can have different values with a list-stat. This is not ideal and can have some performance issues for using a list, but it is still a good way to go.

In addition, the arguments are handled separately for the tag-threshold-value arguments. For the case of PairIntegerTagListCounter, this is also error prone, as the list arguments should be in-sync for matching tag-threshold-value. If option 2 is the way to go, then the arguments might be handled in an easier way as a tagged argument (e.g., --count-pair-int-tag:NM:LT 2 or any variation of that). We should check how plugins interact with tagged arguments, and also if it is worthy to add this complexity for the sake of user-experience.