Skip to content
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

refactor: rewrite Dirichlet::ln_pdf #298

Merged
merged 1 commit into from
Sep 22, 2024

Conversation

FreezyLemon
Copy link
Contributor

The new code should be easier to read and avoids looping through x twice.

The new code also avoids looping through x twice
Copy link

codecov bot commented Sep 22, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 94.03%. Comparing base (a514992) to head (1a6840a).
Report is 4 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #298      +/-   ##
==========================================
- Coverage   94.03%   94.03%   -0.01%     
==========================================
  Files          53       53              
  Lines       12055    12047       -8     
==========================================
- Hits        11336    11328       -8     
  Misses        719      719              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@YeungOnion
Copy link
Contributor

Initially, I thought it made sense to fail before computing any gamma functions, but the failure is panicking, so this seems suitable. Will merge.

@YeungOnion YeungOnion merged commit 1cbcc49 into statrs-dev:master Sep 22, 2024
10 checks passed
@FreezyLemon FreezyLemon deleted the refactor-dirichlet-ln-pdf branch September 23, 2024 04:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants