Skip to content

Commit

Permalink
use Bayesian info criterion to rank models
Browse files Browse the repository at this point in the history
  • Loading branch information
Paradoxdruid committed Mar 22, 2024
1 parent 0d5b9bd commit b4fef14
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion SWV_AnyPeakFinder/logic.py
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ def _return_best_model(
outcomes: list[FitResults] = [each(x, y, center) for each in models]

# Find minimum chisqr and return that model
best_model: FitResults = min(outcomes, key=lambda x: x.chisqr)
best_model: FitResults = min(outcomes, key=lambda x: x.result.bic)

return best_model

Expand Down

0 comments on commit b4fef14

Please sign in to comment.