python-discrete
This is a Pure Python implementation of several discrete probability distributions. There are no external dependencies.
Why would you use this over, say, numpy and scipy? The main reason would be is if, for whatever reason, you’re unable to install C extensions (for example, you need to work with 32-bit Python on a 64-bit system) and just need to generate random events. The Python random module supports generating events for several continuous random distributions not discrete ones, hence this module.
Usage
All implemented distributions are a subclass of the abstract Discrete class, with pdf(k), cdf(k), and generate(n) methods. The generate method returns an array of size n populated with randomly distributed variables from the distribution.
Currently the Poisson and Binomial distributions are implemented. More will likely be added in the future.
Legal
discrete is released under the MIT License; see attached LICENSE file.
Metadata
Release files for discrete 0.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| discrete-0.0.2.tar.gz | 4.6 kB | Without provenance | Details for discrete-0.0.2.tar.gz |
Release files / discrete-0.0.2.tar.gz
| Download URL | discrete-0.0.2.tar.gz |
|---|---|
| Size | 4.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7212cd1b645c2f798abb12b5cf80b44e2623ad2c83ff8ed603999404a8bd2d24
|
|
BLAKE2b-256 checksum How to use checksums |
9a06013d76986dfedab6af098046ac4daf16ee864b437bd8a35cca36e1e906b6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for discrete 0.0.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.