[
https://issues.apache.org/jira/browse/MATH-1065?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13830983#comment-13830983
]
Phil Steitz edited comment on MATH-1065 at 11/24/13 5:17 PM:
-------------------------------------------------------------
I think the intent of this class is to represent a discrete, but real-valued
distribution. EnumeratedDistributions are discrete distributions with a
finite, "enumerated" set of values. The problem here (as Thomas notes) is that
EnumeratedRealDistribution extends AbstractRealDistribution and does not
override the default inverse cum method that basically assumes a continuous
distribution. What it should implement is a discrete algorithm like what
Thomas has suggested.
was (Author: psteitz):
I think the intent of this class is to represent a discrete, but real-valued
distribution. EnumeratedDistributions are discrete distributions with a
finite, "enumerated" set of values. The problem here is that
EnumeratedRealDistribution extends AbstractRealDistribution and does not
override the default inverse cum method that basically assumes a continuous
distribution. What it should implement is something like the discrete
algorithm implemented in AbstractIntegerDistribution. I agree this is a bug
and I think the correct fix is to implement inverseCumulativeProbability in
EnumeratedRealDistribution by adapting the implementation of this method in
AbstractIntegerDistribution.
> EnumeratedRealDistribution.inverseCumulativeProbability returns values not in
> the samples set
> ---------------------------------------------------------------------------------------------
>
> Key: MATH-1065
> URL: https://issues.apache.org/jira/browse/MATH-1065
> Project: Commons Math
> Issue Type: Bug
> Affects Versions: 3.2
> Reporter: matteodg
> Fix For: 4.0, 3.3
>
> Attachments: EnumeratedRealDistributionTest.java
>
>
> The method EnumeratedRealDistribution.inverseCumulativeProbability()
> sometimes returns values that are not in the initial samples domain...
> I will attach a test to exploit this bug.
--
This message was sent by Atlassian JIRA
(v6.1#6144)