Learn R Programming

CUB (version 1.1.5)

simcush: Simulation routine for CUSH models

Description

Generate \(n\) pseudo-random observations following the distribution of a CUSH model without covariates.

Usage

simcush(n,m,delta,shelter)

Arguments

n

Number of simulated observations

m

Number of ordinal categories

delta

Shelter parameter

shelter

Category corresponding to the shelter choice

See Also

probcush

Examples

Run this code
n<-200
m<-7
delta<-0.3
shelter<-3
simulation<-simcush(n,m,delta,shelter)
plot(table(simulation),xlab="Ordinal categories",ylab="Frequencies")

Run the code above in your browser using DataLab