rdir: Dirichlet RNG

Description Usage Arguments Value Author(s) Examples

Description

Generate random draws from a Dirichlet distribution

Usage

1
rdir(n, alpha)

Arguments

n

The number of observations.

alpha

A vector of scale parameters, such that E[p_j] = α_j/∑_iα_i.

Value

An n column matrix containing the observations.

Author(s)

Matt Taddy taddy@chicagobooth.edu

Examples

1
2
rdir(3,rep(1,6))
 

kkdey/classtpx documentation built on May 20, 2019, 10:34 a.m.