Learn R Programming

cases (version 0.1.1)

draw_data_prb: Sample binary data (single sample)

Description

This function is wrapper for rmvbin.

Usage

draw_data_prb(n = 100, pr = c(0.8, 0.8), R = diag(length(pr)))

Value

a matrix with n rows and length(pr) columns of randomly generated binary (0, 1) data

Arguments

n

integer, sample size

pr

numeric, vector with marginal success probabilities

R

matrix, square correlation matrix