-
-
Notifications
You must be signed in to change notification settings - Fork 67
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add metric builder and sorter #826
base: main
Are you sure you want to change the base?
Conversation
Codecov Report
@@ Coverage Diff @@
## main #826 +/- ##
==========================================
- Coverage 95.67% 95.53% -0.15%
==========================================
Files 125 127 +2
Lines 7234 7251 +17
Branches 489 501 +12
==========================================
+ Hits 6921 6927 +6
- Misses 313 324 +11
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
* @param lineNumber optionally, the line number when building a metric from a line in a file | ||
* @return | ||
*/ | ||
def fromLine(line: String, delim: String = Metric.DelimiterAsString, lineNumber: Option[Int] = None): T = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note: need to have different names for each of the from*
methods because I want lineNumber
to default to None
, and I can't have multiple functions with the same name AND each with default values.
Relies on fulcrumgenomics/commons#82 |
* @return a new instance of type [[T]] | ||
*/ | ||
def fromArgMap(argMap: Map[String, String], lineNumber: Option[Int] = None): T = { | ||
reflectiveBuilder.reset() // reset the arguments to their initial values |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Relies on fulcrumgenomics/commons#82
Added a new class
MetricSorter
that's useful when we want to sort metrics but cannot hold them all in memory. LeveragesSorter
.