fermi

A minimalist calculator for estimating with distributions
Log | Files | Refs | README

commit 5f1188c5167bd33b46e37c73043644e4aabbe6ca
parent 6a68bfdc3ba205c854b73365003970d57deaa561
Author: NunoSempere <nuno.semperelh@protonmail.com>
Date:   Sun,  9 Jun 2024 22:48:43 +0200

add type for filled samples & beta distribution

Diffstat:
Mf.go | 13+++++++++++++
1 file changed, 13 insertions(+), 0 deletions(-)

diff --git a/f.go b/f.go @@ -31,6 +31,19 @@ func (l Lognormal) Samples() []float64 { return sample.Sample_parallel(sampler, 1_000_000) } +type Beta struct { + a float64 + b float64 +} + +type FilledSamples struct { + xs []float64 +} + +func (fs FilledSamples) Samples() []float64 { + return fs.xs +} + // Actually, I should look up how do do a) enums in go, b) union types /*type Lognormal struct { low float64