sim_n_persons: Simulate n persons

Description Usage Arguments See Also Examples

Description

Function is a simple replicate wrapper around sim_one_person

Usage

1
sim_n_persons(prob, n, a = 10, ap = rep(1/length(a), length(a)))

Arguments

prob

Probability to draw a construct from a certain category.

n

Number of persons, i.e. grids to be sampled.

a

Possible number of attributes sampled from.

ap

Attribute probabilities, i.e. for each number of attributes given in a.

See Also

Other Simulations: sim_n_persons_x_times_many_n, sim_n_persons_x_times, sim_one_person

Examples

1
2
3
4
sim_n_persons(dexp(1:30, .05), n = 2, a = 10)
sim_n_persons(dexp(1:30, .05), n = 2, a = c(1, 30))
sim_n_persons(dexp(1:30, .05), n = 2, a = c(1, 30), ap = c(1,4))
sim_n_persons(dexp(1:30, .05), n = 2, a = 1:5, ap = c(1,1,2,2,3))

gridsampler documentation built on May 2, 2019, 5:36 a.m.