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

Issue 85: Add infrastructure for analytical solutions in R #87

Merged
merged 10 commits into from
Sep 19, 2024

Conversation

seabbs
Copy link
Contributor

@seabbs seabbs commented Sep 19, 2024

Description

This PR partially closes #85 by adding infrastructure in R for introducing analytical solutions. It also adds skeletons for the current solutions but does not add the analytical solutions themselves.

Checklist

  • My PR is based on a package issue and I have explicitly linked it.
  • I have included the target issue or issues in the PR title in the for Issue(s) issue-numbers: PR title
  • I have read the contribution guidelines.
  • I have tested my changes locally.
  • I have added or updated unit tests where necessary.
  • I have updated the documentation if required.
  • My code follows the established coding standards.
  • I have added a news item linked to this PR.
  • I have reviewed CI checks for this PR and addressed them as far as I am able.

Copy link

codecov bot commented Sep 19, 2024

Codecov Report

Attention: Patch coverage is 90.47619% with 6 lines in your changes missing coverage. Please review.

Project coverage is 98.06%. Comparing base (5c23d7a) to head (9a48117).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
R/primary_censored_dist.R 86.04% 6 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main      #87      +/-   ##
==========================================
- Coverage   99.67%   98.06%   -1.62%     
==========================================
  Files           8       10       +2     
  Lines         310      362      +52     
==========================================
+ Hits          309      355      +46     
- Misses          1        7       +6     

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

This comment was marked as outdated.

This comment was marked as outdated.

@seabbs
Copy link
Contributor Author

seabbs commented Sep 19, 2024

I'm fairly horrified by what I had to do here to get this working but despite that I think its the most sensible approach that retains modularity

Copy link
Contributor Author

@seabbs seabbs left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM (self-review)

Copy link
Contributor

This is how benchmark results would change (along with a 95% confidence interval in relative change) if 596c03f is merged into main:

  • ✔️cmdstan_fit_gamma: 7.7s -> 7.75s [-0.23%, +1.69%]
  • ✔️cmdstan_fit_lognormal: 1.65s -> 1.63s [-5.54%, +3.22%]
  • ❗🐌dprimarycensoreddist_expgrowth: 1.95ms -> 2.34ms [+17.38%, +22.82%]
  • ❗🐌dprimarycensoreddist_weibull: 1.87ms -> 2.27ms [+18.7%, +24.27%]
  • ❗🐌fitdistdoublecens_gamma: 665ms -> 678ms [+0.92%, +3.01%]
  • ❗🐌fitdistdoublecens_normal: 557ms -> 562ms [+0.65%, +1.47%]
  • ❗🐌pprimarycensoreddist_expgrowth: 37.5ms -> 45.4ms [+19.21%, +23.35%]
  • ❗🐌pprimarycensoreddist_lnorm: 34.4ms -> 42.2ms [+20.52%, +25.38%]
    Further explanation regarding interpretation and methodology can be found in the documentation of touchstone.

@seabbs
Copy link
Contributor Author

seabbs commented Sep 19, 2024

Test gaps are due to the current lack of analytical solutions so I think this is good to go.

@seabbs seabbs merged commit 7c336a0 into main Sep 19, 2024
9 of 10 checks passed
@seabbs seabbs deleted the analytical-infra branch September 19, 2024 16:10
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.

Implement analytical solutions in R and stan
1 participant