Learn R Programming

nhppp (version 1.0.2)

rztpois: Zero-truncated Poisson random samples (basic R)

Description

Sample zero-truncated Poisson random samples (basic R)

Usage

rztpois(n, lambda)

Value

a vector of non zero counts of size n

Arguments

n

Integer, number of samples

lambda

Positive number, the mean of the original (untruncated) Poisson distribution

Examples

Run this code
rztpois(10, 1)
rztpois(10, 1:10)

Run the code above in your browser using DataLab