sampleFrom: Sample from a distribution object

Description Usage Arguments Value Author(s) Examples

Description

Generates samples from a distribution held by an object of class distribution or mvdistribution. Intended mainly for internal use.

Usage

1
sampleFrom(dstn, n = 1)

Arguments

dstn

an object of class distribution or mvdistribution.

n

Number of samples to generate

Value

A vector or matrix of samples.

Author(s)

Francisco Gochez <fgochez@mango-solutions.com>

Examples

1
2
    x <- distribution("pois", lambda = 5)
    hist(sampleFrom(x, 1000), col = "blue", prob = TRUE)

BLCOP documentation built on Jan. 26, 2021, 1:05 a.m.