| Crates.io | stochasta |
| lib.rs | stochasta |
| version | 0.8.3 |
| created_at | 2021-12-30 14:42:58.010604+00 |
| updated_at | 2024-05-25 23:26:31.339963+00 |
| description | A simple stochastic analysis library |
| homepage | |
| repository | https://github.com/leun4m/stochasta |
| max_upload_size | |
| id | 505362 |
| size | 81,546 |
This is stochasta.
A (hopefully) simple stochastic analysis library.
It is written in Rust and published at crates.io.
use stochasta::CardDeck;
use stochasta::Probability;
fn main() {
let coin = CardDeck::from(vec!["heads", "tails"]);
assert_eq!(coin.size(), 2);
assert_eq!(coin.probability(&"heads"), Probability::new(1, 2));
assert_eq!(coin.probability(&"tails"), Probability::new(1, 2));
}
More examples can be found in the examples directory (cargo run --example <example-name>).
The complete documentation is hosted at docs.rs/stochasta.
For Changelog / News / History / Releases, see CHANGELOG.md.
If there is anything at your disfavor or something behaves weird, please submit an issue or open a pull request.