-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
42798bf
commit 29ddbb6
Showing
15 changed files
with
148 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
\nonstopmode{} | ||
\documentclass[a4paper]{book} | ||
\usepackage[times,inconsolata,hyper]{Rd} | ||
\usepackage{makeidx} | ||
\usepackage[utf8]{inputenc} % @SET ENCODING@ | ||
% \usepackage{graphicx} % @USE GRAPHICX@ | ||
\makeindex{} | ||
\begin{document} | ||
\chapter*{} | ||
\begin{center} | ||
{\textbf{\huge \R{} documentation}} \par\bigskip{{\Large of \file{C:/Users/Usuario/OneDrive - Universidad Pontificia Comillas/Programación/GitHub/cdmTools} etc.}} | ||
\par\bigskip{\large \today} | ||
\end{center} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
Version: 1.0.3 | ||
Date: 2023-03-30 13:39:41 UTC | ||
SHA: b91779562fc4a44ee56fa282d810ecd52b095e5a | ||
Version: 1.0.4 | ||
Date: 2023-11-14 14:30:10 UTC | ||
SHA: ce3c3f87fc179f26bec0810d9a5ada0b58fec136 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
Package: cdmTools | ||
Type: Package | ||
Title: Useful Tools for Cognitive Diagnosis Modeling | ||
Version: 1.0.4 | ||
Date: 2023-11-14 | ||
Version: 1.0.5 | ||
Date: 2024-01-03 | ||
Authors@R: c(person(given = "Pablo", family = "Nájera", role = c("aut", "cre", "cph"), email = "[email protected]"), person(given = "Miguel A.", family = "Sorrel", role = c("aut", "cph"), email = "[email protected]"), person(given = "Francisco J.", family = "Abad", role = c("aut", "cph")), person(given = "Rodrigo S.", family = "Kreitchmann", role = c("ctb")), person(given = "Kevin", family = "Santos", role = c("ctb"))) | ||
Description: Provides useful tools for cognitive diagnosis modeling (CDM). The package includes functions for empirical Q-matrix estimation and validation, such as the Hull method (Nájera, Sorrel, de la Torre, & Abad, 2021, <doi:10.1111/bmsp.12228>) and the discrete factor loading method (Wang, Song, & Ding, 2018, <doi:10.1007/978-3-319-77249-3_29>). It also contains dimensionality assessment procedures for CDM, including parallel analysis and automated fit comparison as explored in Nájera, Abad, and Sorrel (2021, <doi:10.3389/fpsyg.2021.614470>). Other relevant methods and features for CDM applications, such as the restricted DINA model (Nájera et al., 2023; <doi:10.3102/10769986231158829>), the general nonparametric classification method (Chiu et al., 2018; <doi:10.1007/s11336-017-9595-4>), and corrected estimation of the classification accuracy via multiple imputation (Kreitchmann et al., 2022; <doi:10.3758/s13428-022-01967-5>) are also available. Lastly, the package provides some useful functions for CDM simulation studies, such as random Q-matrix generation and detection of complete/identified Q-matrices. | ||
License: GPL-3 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
#' Translate RDINA object into GDINA object | ||
#' | ||
#' @description This function translates an object of class \code{RDINA} to an object of class \code{GDINA}, so that the estimated R-DINA object is compatible with most of the functions in the \code{GDINA} package (Ma & de la Torre, 2020), including model fit, item fit, and Q-matrix validation. | ||
#' | ||
#' @param fit An object of class \code{RDINA}. | ||
#' | ||
#' @return \code{RDINA2GDINA} returns an object of class \code{GDINA}. See the \code{GDINA} package for more information. | ||
#' | ||
#' @author {Pablo Nájera, Universidad Pontificia Comillas} | ||
#' | ||
#' @references | ||
#' Ma, W., & de la Torre, J. (2020). GDINA: An R package for cognitive diagnosis modeling. \emph{Journal of Statistical Software}, \emph{93}(14). https://doi.org/10.18637/jss.v093.i14 | ||
#' | ||
#' @export | ||
#' | ||
#' @examples | ||
#' \donttest{ | ||
#' library(GDINA) | ||
#' dat <- sim30DINA$simdat | ||
#' Q <- sim30DINA$simQ | ||
#' fit1 <- RDINA(dat, Q) | ||
#' fit2 <- RDINA2GDINA(fit1) | ||
#' modelfit(fit2) # Model fit evaluation | ||
#' itemfit(fit2) # Item fit evaluation | ||
#' } | ||
RDINA2GDINA <- function(fit){ | ||
if(!inherits(fit, "RDINA")){stop("Error in RDINA2GDINA: fit must be of class 'RDINA'.")} | ||
dat <- fit$specifications$dat | ||
Q <- fit$specifications$Q | ||
N <- nrow(dat) | ||
J <- nrow(Q) | ||
K <- ncol(Q) | ||
L <- 2^K | ||
phi <- fit$phi | ||
catprob.parm <- list() | ||
for(j in 1:J){ | ||
lj <- 2^sum(Q[j,]) | ||
if(fit$specifications$gate == "AND"){ | ||
catprob.parm[[j]] <- c(rep(phi, lj - 1), 1 - phi) | ||
} else { | ||
catprob.parm[[j]] <- c(phi, rep(1 - phi, lj - 1)) | ||
} | ||
} | ||
model <- ifelse(fit$specifications$gate == "AND", "DINA", "DINO") | ||
res <- GDINA::GDINA(dat, Q, model = model, catprob.parm = catprob.parm, control = list(maxitr = 0), verbose = 0) | ||
res$struc.parm <- as.numeric(fit$post.probs$lp) | ||
res$testfit[3] <- 1 | ||
res$testfit[-3] <- fit$test.fit | ||
res$technicals$free.item.npar <- 1 | ||
res$technicals$total.npar <- L | ||
res$extra$call <- "RDINA" | ||
return(res) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,28 @@ | ||
## cdmTools_1.0.5 (January 03, 2024) | ||
|
||
#### News & Comments | ||
* We have added the RDINA2GDINA function | ||
* We have slightly modified the CA.MI and personFit functions | ||
* We have listed Kevin Santos as a contributor | ||
|
||
#### Test envirnoments | ||
* Local Windows 10 x64, R 4.1.2 | ||
* Ubuntu Linux 16.04 LTS, R-release, GCC (check_rhub) | ||
* Windows Server 2008 R2 SP1, R-devel, 32/64 bit (check_rhub) | ||
* Fedora Linux, R-devel, clang, gfortran (check_rhub) | ||
* (check_win_devel) | ||
|
||
#### R CMD check results | ||
|
||
* There were no ERRORs or WARNINGs. | ||
* There was 1 NOTE: | ||
``` | ||
Maintainer: 'Pablo Nájera <[email protected]>' | ||
Uses the superseded package: 'doSNOW' | ||
``` | ||
The `doSNOW` package is required to show a progress bar inside a `foreach` loop. | ||
|
||
## cdmTools_1.0.4 (November 10, 2023) | ||
|
||
#### News & Comments | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.