Please can someone explain to me how to use randomLCA in R for an analysis.
I tried using it and had this error (copied below) which indicated my
patterns must consist of 0 or 1. I assume I am doing something wrong.
Please help.



> library(lattice)
> library(boot)

Attaching package: ‘boot’

The following object(s) are masked from ‘package:lattice’:

    melanoma

> library(utils)
> library(randomLCA)
> #random parameter latent class model
> trt.lca1random <-
randomLCA(trt[,1:5],initmodel=0,nclass=1,random=TRUE,quadpoints=41,probit=TRUE)
Error in randomLCA(trt[, 1:5], initmodel = 0, nclass = 1, random = TRUE,  :
  patterns must consist of either 0 or 1
> trt.lca2random <-
randomLCA(trt[,1:5],initmodel=0,nclass=2,random=TRUE,quadpoints=41,probit=TRUE)
Error in randomLCA(trt[, 1:5], initmodel = 0, nclass = 2, random = TRUE,  :
  patterns must consist of either 0 or 1

Thanks,
Bismark

	[[alternative HTML version deleted]]

