Skip to content

Future of distributions in rand #290

Closed
@vks

Description

@vks

When working with distributions it is very useful to have access to their density, their distribution function and their quantile function in addition to being able to sample from them. Furthermore, it is nice to be able to calculate their (theoretical, exact) moments. I think it makes sense to have all this functionality in a common interface.

This is implemented in the statrs crate. There is some overlap with rand, sampling is implemented there as well, but for a lot more distributions.

I see the following options:

  1. Only implement sampling in rand. Port the missing distributions from statrs to rand.
  2. Also implement the theoretical properties of the distributions mentioned above in rand, essentially duplicating statrs.
  3. Remove the distributions from rand and suggest to use statrs instead.

What do you think?

Metadata

Metadata

Assignees

No one assigned

    Labels

    B-APIBreakage: APIE-questionParticipation: opinions wantedP-lowPriority: Low

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions