Comments (5)
Přikládám možnou úpravu pomocí mirt
balíčku, která celou záložku IRT models výrazně zrychlí. mirt
poskytuje podobné obrázky jako ltm
, navíc má však dobře naprogramované (rychlé a obecné) funkce k vyhodnocení modelů atd. - viz zdroják
library(difNLR)
library(mirt)
data(GMAT)
data <- GMAT[, 1:20]
### IRT models
###### Rasch model model = 1, itemtype = "Rasch", constrain = NULL
###### 1PL with the fixed discrimination
###### model <- 'F = 1-20
###### CONSTRAIN = (1-20, a1)'
###### nebo
###### model = 1, itemtype = "2PL", constrain = list((1:ncol(data)) + seq(0, (ncol(data) - 1)*3, 3))
###### 2PL model = 1, itemtype = "2PL", constrain = NULL
###### 3PL model = 1, itemtype = "3PL", constrain = NULL
fitR <- mirt(data, model, itemtype = itemtype, constrain = constrain)
# COEF
coef(fitR)
# PLOTS
# expected total score
plot(fitR, type = "score")
# test information function
plot(fitR, type = "info")
# reliability
plot(fitR, type = "rxx")
# test standard errors
plot(fitR, type = "SE")
# item trace lines - characteristic curves multiple figure
plot(fitR, type = "trace")
plot(fitR, type = "trace", facet_items = F)
# item information trace lines - multiple figure
plot(fitR, type = "infotrace")
plot(fitR, type = "infotrace", facet_items = F)
# expected item scoring function - multiple figure
plot(fitR, type = "itemscore")
plot(fitR, type = "itemscore", facet_items = F)
# test information and standard errors - combination
plot(fitR, type = "infoSE")
# factor scores
fs <- fscores(fitR)
sts <- as.vector(scale(apply(data, 1, sum)))
df <- data.frame(fs, sts)
ggplot(df, aes_string("sts", "fs")) +
geom_point(size = 3) +
labs(x = "Standardized total score", y = "Factor score") +
theme_bw() +
theme(text = element_text(size = 14),
plot.title = element_text(face = "bold", vjust = 1.5),
axis.line = element_line(colour = "black"),
panel.grid.major = element_blank(),
panel.grid.minor = element_blank(),
panel.background = element_blank()) +
theme(legend.box.just = "left",
legend.justification = c(1, 0),
legend.position = c(1, 0),
legend.box = "vertical",
legend.key.size = unit(1, "lines"),
legend.text.align = 0,
legend.title.align = 0)
### comparing two models
fit1 <- mirt(data, 1, "Rasch")
fit2 <- mirt(data, 1, "2PL")
anova(fit1, fit2)
### person fit
personfit(fitR)
`
from shinyitemanalysis.
mirt vypada velmi dobre! Bylo by mozne vytvorit jej zatim jako samostatny list?
from shinyitemanalysis.
- mirt přidán jako samostatný list
- models comparison přidáno jako další záložka v IRT models
Co je ještě potřeba?
from shinyitemanalysis.
mirt vypada pekne.
Zatim nam zlobi pridani baliku mirt na Shiny server. Nejake napady? Hlasi to toto:
- installing source package ‘RcppArmadillo’ ...
** package ‘RcppArmadillo’ successfully unpacked and MD5 sums checked
checking whether the C++ compiler works... yes
checking for C++ compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C++ compiler... yes
checking whether g++ -m64 accepts -g... yes
checking how to run the C++ preprocessor... g++ -m64 -E
checking whether we are using the GNU C++ compiler... (cached) yes
checking whether g++ -m64 accepts -g... (cached) yes
checking whether g++ version is sufficient... no
configure: WARNING: Only g++ version 4.6 or greater can be used with RcppArmadillo.
configure: error: Please use a different compiler.
ERROR: configuration failed for package ‘RcppArmadillo’ - removing ‘/usr/lib64/R/library/RcppArmadillo’
ERROR: dependency ‘RcppArmadillo’ is not available for package ‘mirt’
Kompiler prý nemá update.
from shinyitemanalysis.
U mě to funguje bez problémů, zde radí spustit R v režimu R --vanilla
a pak až nainstalovat balíčky.
Teď jsem ještě našla debatu vývojářů přímo na GitHubu. Snad to pomůže!
from shinyitemanalysis.
Related Issues (20)
- Regression plot description HOT 1
- Bugs in plotDIFirt() HOT 1
- Plotting DIF ICCs HOT 2
- Hexbin in footer HOT 2
- HTML generation on CS.CAS.CZ server HOT 2
- Section headings not well visible when using smartphone HOT 2
- PDF generation on cemp.shinyapps.io/ShinyItemAnalysis HOT 1
- Page acceess count on shinyapps.io HOT 2
- Analyses of ordinal data HOT 1
- Loading group vector with missing values HOT 2
- Errored occured when using "startShinyItemAnalysis()" on Windows 10 HOT 6
- Error after excuting startShinyItemAnalysis() HOT 5
- After updating R to 4-0-4 recent version, ShinyItemAnalysis does not work HOT 3
- Upload data loading! HOT 5
- Total Scores and data HOT 3
- Data is read incorrectly HOT 5
- Disconnecting while trying to read in data HOT 3
- disconnections HOT 2
- Plot legend is duplicated in black HOT 2
- No issue, just an idea HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from shinyitemanalysis.