dice-stats

command module
v0.0.0-...-c5a8b54 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 7, 2017 License: Unlicense Imports: 8 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

Dice Probability Distribution Software

This software generate probability distribution for a given dice throw.

Dice Logo

Download

System 32-bit 64-bit
Windows dice-stats-windows-386.tar.gz dice-stats-windows-amd64.tar.gz
Linux dice-stats-linux-386.tar.gz dice-stats-linux-amd64.tar.gz
OSX dice-stats-darwin-386.tar.gz dice-stats-darwin-amd64.tar.gz

Throw query format

{n}d{m}(k{p}) where:

  • n: number of dice to throw
  • m: number of faces of each dice
  • p: number of best dice results to keep

Examples: 2d6, 3d10, 7d6k3.

Prompt use

> Throw query:

Requires a string that must follow the Throw query format.

> Versus throw query (leave empty to ignore)

Can be a string that must follow the Throw query format or be empty in order to skip.
If provided, it will generate win probabilities for first throw quiery against this one.

Command use

The only argument required is a string query following the Throw query format.

Command Option
Iterations
  • Syntax: -i
  • Type: int
  • Default: 1000000
  • Example: > ./dice-stats -i=10000 2d6

Number of iterations to use in order to define probabilities accuracy.

Versus
  • Syntax: -vs
  • Type: string using throw query format
  • Default: none
  • Example: > ./dice-stats -vs=3d6 2d6

Use another dice throw and compare chances to win against this one.

Example

Generate probability distribution for throwing 2 dice with 6 faces:

> ./dice-stats 2d6

Generate probability distribution for throwing 3 dice with 10 faces:

> ./dice-stats 3d10

Generate probability distribution for throwing 7 dice with 6 faces and keeping the 3 best results:

> ./dice-stats 7d6k3

Generate probability distribution of winning throwing 7 dice with 6 faces and keeping the 3 best results against 5 dice with 6 faces and keeping the 3 best:

> ./dice-stats -vs=5d6k3 7d6k3

Generate probability distribution of winning throwing 17 dice with 4 faces and keeping the 9 best results against 25 dice with 4 faces and keeping the 6 best:

> ./dice-stats -vs=25d4k6 17d4k9

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
⌂ 换网址