sim_individuals {diverse}R Documentation

A procedure to simulate labeled individuals for one category

Description

Simulates a number of individuals tagged in N different categories, given a distribution such as log normal or normal.

Usage

sim_individuals(n_categ, size, category_prefix = "", type = "log-normal",
  mean = 0, sd = 1)

Arguments

n_categ

number of categories

size

number of individuals.

category_prefix

a prefix to be used as part of the category label

type

distribution name. The distribution is used to simulate how individuals are created. Use 'log-normal' for log normal distribution or 'normal' for normal distribution. Default value is 'log-normal'

mean

parameter for normal or log-normal distribution. Default value is 0.

sd

parameter for normal or log-normal distribution. Default value is 1.

Value

A vector of category labels.

Examples

sim_individuals(n_categ=50, size=10000, type='log-normal', mean=0.507, sd=1.183)

[Package diverse version 0.1.5 Index]