Description Usage Arguments Value Author(s) See Also Examples
std_coef
compute standardized factor loading parameter estimates and correlation matrix.
std_cov
scales a covariance matrix into the corresponding correlation matrix.
1 2 3 4 |
est |
a vector of loading parameter estimates from |
dim_info |
a list of items for each dimension |
cov_matrix |
a square numeric variance_covariance matrix |
std_coef
returns a list of standardized loading parameter estimates and correlation matrix.
std_cov
returns a correlation matrix.
Minjeong Jeon <jeon.117@osu.edu>
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 | library(flirt)
## verbal aggression data: polytmous item responses
data(verb2)
# 2-dimensional 2PL model for binary data
# a*th + b parameterization
model1 <- flirt(data=resp, loading=list(on=TRUE, inside=FALSE),
mul=list(on=TRUE, dim_info=list(dim1=1:12, dim2=13:24)) , control=list(nq=5) )
## function for standardized loadings and covariance matrix
# length 24, unstandardized loading parameter estimates
est <- coef(model1)[1:24,1]
# length 3 (sd1, cov12, sd2) unstandardized sd and cov estimates vector
cov_el <- coef(model1)[51:53,1]
# covariance matrix
cov_matrix <- matrix(c(cov_el[1]^2,cov_el[3], cov_el[3],cov_el[2]^2),2,2, byrow=FALSE)
# list
dim_info <- list(dim1=1:12, dim2=13:24)
test0 <- std_coef(est=est, dim_info=dim_info, cov_matrix= cov_matrix)
test1 <- std_cov(dim_info=dim_info, cov_matrix= cov_matrix)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.