Welcome to statty.js’s documentation!

Features

  • Generate random numbers from different distributions
  • Fit data to a distribution using the MLE
  • Distributions each have the following
    • attributes: mean and variance
    • functions: pdf or pmf, cdf, quantile and rand
    • initializer: fit (except the Bernoulli)

Installation

Using npm:

npm install statty.js

Or clone the repo and put it in your project:

git clone https://github.com/r0fls/statty.js.git
mv statty.js your/project/path

Distributions

Continuous

  • Normal
  • Uniform
  • Laplace
  • Pareto
  • Exponential

Discrete

  • Bernoulli
  • Binomial
  • Geometric
  • Poisson