Gilles Sadowski wrote:
> Hello.
> 
>> Hmm... no this is not dependent on CM.  This is an example that I wrote in 3
>> minutes to illustrate the point.
>>
>> I think the confusion is that I assumed that commons.math distributions
>> supported sampling.  I don't think that capability is available even now
>> (although a user contributed patches months ago to do that).  My example is
>> geared towards that.
> 
> Where has this patch gone?
> 
>> The problem is probably mine.  I haven't been using commons math since the
>> Mahout project decided that it wasn't usable for our needs and I assumed
>> that this basic capability was available.
>>
>> If distributions are viewed only as a pure function that computes the
>> density and cumulative distribution function, then what I say has no
>> utility, but then again, without sampling distributions are also much less
>> useful.
> 
> So, maybe this should be the starting point: adding this feature to the
> distribution classes. Which gets back to the above question...

The sampling patch is in MATH-310, but this is irrelevant to the
question of whether or not to deprecate the property setters.

I am -1 on implementing the patch in MATH-310 as provided.  This
functionality belongs in the random package, where it already exists
for some distributions. Inversion is just one way to generate
deviates and including a potentially bad impl with every
distribution is not a good idea, IMO, beyond the issue of separation
of concerns.  See discussion here, where I suggested an alternative
way to extend to other distributions:

http://markmail.org/message/kolivuytbt5cj25s

It is on my todo list to resolve MATH-310 by implementing the
extension to RandomData described there.  Patches, alternatives
welcome.  I am open to alternatives, but I will need clear, simple,
practical arguments explaining why it is not bad separation of
concerns to duplicate all of this into the distributions classes
themselves, or a good argument for why we should deprecate the
random package.

Phil




> 
> Best,
> Gilles
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org
> For additional commands, e-mail: dev-h...@commons.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@commons.apache.org
For additional commands, e-mail: dev-h...@commons.apache.org

Reply via email to