Rasch Model - Constrain latent variance to 1

59 visualizzazioni
Passa al primo messaggio da leggere

June Kuo

da leggere,
21 feb 2018, 16:48:1821/02/18
a mirt-package
Hi Phil,

Is it possible to constrain latent variance to 1 when running the Rasch model? I tried to use mirt.model but it only worked in the 2PL and 3PL models. I tried below but all gave free COV estimation:

- Result_1PL = mirt(Data, 1, itemtype = "Rasch")


- Q = matrix(1, c(ncol(Data), 1)); colnames(Q) = paste0("Factor", 1)
  COV = FALSE
  Model_U = mirt.model(Q, COV = COV)

Result_1PL = mirt(Data, Model_U, itemtype = "Rasch")


Thanks

Phil Chalmers

da leggere,
21 feb 2018, 17:51:5521/02/18
a June Kuo, mirt-package
Hi June,

The latent trait model is technically the "J + 1"th item in the mirt.model() definition, though in the next major release I'll probably make a more elegant name to access this internally object instead (it will likely be labelled GROUP, to reflect the starting values name assigned internally). See below though for a working example. 

library(mirt)
data <- expand.table(LSAT7)
model <- "F = 1-5
         FIXED = (6, COV_11)
         START = (6, COV_11, 1.0)"

mod1 <- mirt(data, model, itemtype = "Rasch", SE=TRUE)
coef(mod1)

Phil

--
You received this message because you are subscribed to the Google Groups "mirt-package" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mirt-package+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

June Kuo

da leggere,
22 feb 2018, 09:21:4222/02/18
a mirt-package
Thank you Phil,

I got an error when I ran the working example you provided. Could you please tell me where I did wrong?

> library(mirt)
> data <- expand.table(LSAT7)
> model <- "F = 1-5
+ FIXED = (6, COV_11)
+ START = (6, COV_11, 1.0)"
> mod1 <- mirt(data, model, itemtype = "Rasch", SE=TRUE)
Error in FUN(X[[i]], ...) : 
  trying to get slot "par" from an object of a basic class ("NULL") with no slots

Thanks,
June

Phil

To unsubscribe from this group and stop receiving emails from it, send an email to mirt-package...@googlegroups.com.

Phil Chalmers

da leggere,
22 feb 2018, 10:33:1122/02/18
a June Kuo, mirt-package
Hi June,

Are you running the latest version of mirt (1.26.3) from CRAN? It should work with that version. Also, with the new dev version the following syntax is now valid, which will appear in the next major release:

library(mirt)
data <- expand.table(LSAT7)
model <- "F = 1-5
         FIXED = (GROUP, COV_11)
         START = (GROUP, COV_11, 1.0)"

mod1 <- mirt(data, model, itemtype = "Rasch", SE=TRUE)
coef(mod1)


Phil

To unsubscribe from this group and stop receiving emails from it, send an email to mirt-package+unsubscribe@googlegroups.com.

June Kuo

da leggere,
22 feb 2018, 16:54:0822/02/18
a mirt-package
Thank you Phil,

After deleting the older version and installing the latest version of mirt, it finally worked. Thanks for your help!

June
Rispondi a tutti
Rispondi all'autore
Inoltra
0 nuovi messaggi