-
Notifications
You must be signed in to change notification settings - Fork 45
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This PR adds a `pmf` and `log_pmf` method to the base interface. Fixes #289 In accordance with #229, these return 0 resp `-np.inf` if the distribution is continuous. Also makes the following, connected changes: * `pdf` return 0 for discrete distributions * removes the discrete/continuous handling logic from the `scipy` adapter, as this is now in the base class I've also changed the way in which `TestScipyAdapter` queries the distributions - by inheritance, not by tag. This is since the tag is "mechanical" (for internal testing only) and it might confuse users to see a value in `object_type` which is not related to an external API property.
- Loading branch information
Showing
5 changed files
with
158 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters