Skip to content

Probability Distribution and Statistical Functions -- Gamma Distribution Module#278

Closed
Jim-215-Fisher wants to merge 48 commits into
fortran-lang:masterfrom
Jim-215-Fisher:Distribution-Gamma
Closed

Probability Distribution and Statistical Functions -- Gamma Distribution Module#278
Jim-215-Fisher wants to merge 48 commits into
fortran-lang:masterfrom
Jim-215-Fisher:Distribution-Gamma

Conversation

@Jim-215-Fisher

@Jim-215-Fisher Jim-215-Fisher commented Dec 22, 2020

Copy link
Copy Markdown
Contributor

This is the second round of probability distribution and statistical functions, continuing from #240. Since the whole modular structure has been changed, each distribution will have its own PR.
This PR contains gamma distributions. Files uploaded are:

  • src/stdlib_stats_distribtuion_gamma.fypp
  • src/CMakeLists.txt
  • src/tests/test_distribution_gamma.f90
  • src/tests/CMakeLists.txt
  • doc/specs/stdlib_stats_distribution_gamma.md
  • doc/specs/index.md

Link to the open-access article on which this PR is based.
P.369 (7/10) has a summary of the final algorithm.

@awvwgk awvwgk added the reviewers needed This patch requires extra eyes label Apr 17, 2021
@awvwgk awvwgk added the topic: statistics Statistical functions label Sep 18, 2021
@Jim-215-Fisher Jim-215-Fisher marked this pull request as draft September 22, 2021 00:08
@Jim-215-Fisher Jim-215-Fisher marked this pull request as ready for review June 20, 2022 18:46
@Jim-215-Fisher

Copy link
Copy Markdown
Contributor Author

This one is ready for review.

Comment thread doc/specs/stdlib_stats_distribution_gamma.md Outdated
@Jim-215-Fisher

Copy link
Copy Markdown
Contributor Author

Compilation failed due to Build-API-Docs failure of other modules. Error message is AttributeError: 'FortranSubmoduleProcedure' object has no attribute 'module'. What does that mean?

@14NGiestas

Copy link
Copy Markdown
Member

@Jim-215-Fisher it looks related to the ford issue ford#466.
Apart from that, this PR is LGTM. The only thing I'm unsure about it is: How was your approach to testing, and where did you get the expected output?

@Jim-215-Fisher

Copy link
Copy Markdown
Contributor Author

Thank you for the info. Regarding the testing, gamma random number is tested with common Pearson's chi-squared test, pdf and cdf were tested against results from scipy or excel formula with the same parameters.

@Jim-215-Fisher it looks related to the ford issue ford#466. Apart from that, this PR is LGTM. The only thing I'm unsure about it is: How was your approach to testing, and where did you get the expected output?

@Calluumm

Copy link
Copy Markdown
Contributor

Continued and modernised this in #1099

@14NGiestas 14NGiestas closed this May 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

reviewers needed This patch requires extra eyes topic: statistics Statistical functions

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants