Skip to content

Commit

Permalink
Makes sure design names are different from latent variables
Browse files Browse the repository at this point in the history
  • Loading branch information
philchalmers committed Jan 17, 2013
1 parent 53a4376 commit a392ecd
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions R/mixedmirt.R
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,8 @@ mixedmirt <- function(data, covdata = NULL, model, fixed = ~ 1, random = NULL, i
stop('No fixed or random effects have been specified.')
Theta <- matrix(0, nrow(data), nrow(model$x))
colnames(Theta) <- model$x[,1]
if(any(colnames(Theta) %in% colnames(covdata)) || any(colnames(Theta) %in% colnames(itemdesign)))
stop('Predictor variable names must be different from latent variable names.')
fixed.identical <- FALSE
if(all(itemdesign == 1)) fixed.identical <- TRUE
fixed.design.list <- designMats(covdata=covdata, fixed=fixed, Thetas=Theta, nitems=ncol(data),
Expand Down

0 comments on commit a392ecd

Please sign in to comment.