Skip to content

Commit

Permalink
removed match statement from hyperscore cal
Browse files Browse the repository at this point in the history
  • Loading branch information
theGreatHerrLebert authored and lazear committed Oct 17, 2024
1 parent 5cc9ec6 commit 888afad
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions crates/sage/src/scoring.rs
Original file line number Diff line number Diff line change
Expand Up @@ -189,10 +189,7 @@ impl ScoreType {
impl Score {
/// Calculate the hyperscore for a given PSM choosing between implementations based on `score_type`
fn hyperscore(&self, score_type: ScoreType) -> f64 {
match score_type {
ScoreType::SageHyperScore => ScoreType::SageHyperScore.score(self.matched_b, self.matched_y, self.summed_b, self.summed_y),
ScoreType::OpenMSHyperScore => ScoreType::OpenMSHyperScore.score(self.matched_b, self.matched_y, self.summed_b, self.summed_y),
}
score_type.score(self.matched_b, self.matched_y, self.summed_b, self.summed_y)
}
}

Expand Down

0 comments on commit 888afad

Please sign in to comment.