trunc_geom: Geometric distribution sampler truncated to a maximum

View source: R/utils.R

trunc_geomR Documentation

Geometric distribution sampler truncated to a maximum

Description

A geometric distribution sampler with probability 'p' restricted to values inside [1, max]. Because of this restriction, very low values of 'p' coupled with low 'max' return increasingly uniform populations in the interval [1, max].

Usage

trunc_geom(p, max)

Arguments

p

the parameter of the geometric distribution

max

the maximum value allowed to be sampled

Value

the sampled value


dbnR documentation built on Oct. 5, 2022, 1:07 a.m.