Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,6 @@ README.html
^\.github$
^\.git$
^validate_package\.R$
^validate_report\.json$
^validate_report\.json$
^AGENTS\.md$
^build_package\.R$
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -54,3 +54,4 @@ rsconnect/
validate_report.json
validate_package.R
build_package.R
AGENTS.md
3 changes: 3 additions & 0 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,9 @@ LazyData: true
Imports:
boot,
ggplot2,
ggrepel,
MASS,
rlang,
stats,
utils
Depends:
Expand Down
3 changes: 3 additions & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ export(SVALmult)
export(SVALplot)
export(SVALsingle)
export(Vaiken)
export(Vaikenpub)
export(minimumCV)
importFrom(boot,
boot,
boot.ci
Expand All @@ -42,6 +44,7 @@ importFrom(ggplot2,
theme,
theme_minimal
)
importFrom(rlang,.data)
importFrom(stats,
complete.cases,
na.omit,
Expand Down
6 changes: 3 additions & 3 deletions R/CID.R
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@
#'
#'Merino-Soto, C. (2023). Coeficientes V de Aiken: diferencias en los juicios de validez de contenido. MHSalud, 20(1), 23-32. https://doi.org/10.15359/mhs.20-1.3
#'
#'Singer, J. (2010). Construction of confidence limits about effect measures: A general approach, by G. Y. Zou and A. Donner, Statistics in Medicine 2008; 27:1693-1702. Statistics in Medicine, 29(16), 1757–1759. https://doi.org/10.1002/sim.3887
#'Singer, J. (2010). Construction of confidence limits about effect measures: A general approach, by G. Y. Zou and A. Donner, Statistics in Medicine 2008; 27:1693-1702. Statistics in Medicine, 29(16), 1757-1759. https://doi.org/10.1002/sim.3887
#'
#'Zou, G.Y. and Donner, A. (2008) Construction of confidence limits about effect measures: a general approach. Stat. Med. 27, 1693–1702. https://doi.org//10.1002/sim.3095
#'Zou, G.Y. and Donner, A. (2008) Construction of confidence limits about effect measures: a general approach. Stat. Med. 27, 1693-1702. https://doi.org//10.1002/sim.3095
#'
#'@author
#'Cesar Merino-Soto (\email{sikayax@yahoo.cam.ar})
Expand Down Expand Up @@ -107,7 +107,7 @@ CID <- function(group1, group2, coef.col = "coef", lwr.col = "lwr.ci", upr.col =
stop("Ambos argumentos 'group1' y 'group2' deben ser data.frames.")
}

# Detección de valores perdidos
# Deteccion de valores perdidos
if (!na.rm) {
if (any(is.na(group1)) || any(is.na(group2))) {
stop("Valores perdidos detectados. Usa na.omit() primero o establece na.rm=TRUE.")
Expand Down
6 changes: 3 additions & 3 deletions R/CIDsingle.R
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,13 @@
#'
#'Aiken, L. R. (1985). Three coefficients for analyzing the reliability and validity of ratings. Educational and Psychological Measurement, 45, 131-142. https://doi.org/10.1177/0013164485451012
#'
#'Merino-Soto, C. (2018) Confidence interval for difference between coefficients of content validity (Aiken's V): a SPSS syntax. Anales de Psicología, 34(3), 587-590. https://doi.org/10.6018/analesps.34.3.283481.
#'Merino-Soto, C. (2018) Confidence interval for difference between coefficients of content validity (Aiken's V): a SPSS syntax. Anales de Psicologia, 34(3), 587-590. https://doi.org/10.6018/analesps.34.3.283481.
#'
#'Merino-Soto, C. (2023). Coeficientes V de Aiken: diferencias en los juicios de validez de contenido. MHSalud, 20(1), 23-32. https://doi.org/10.15359/mhs.20-1.3
#'
#'Singer, J. (2010). Construction of confidence limits about effect measures: A general approach, by G. Y. Zou and A. Donner, Statistics in Medicine 2008; 27:1693-1702.Statistics in Medicine, 29(16), 1757–1759. https://doi.org/10.1002/sim.3887
#'Singer, J. (2010). Construction of confidence limits about effect measures: A general approach, by G. Y. Zou and A. Donner, Statistics in Medicine 2008; 27:1693-1702.Statistics in Medicine, 29(16), 1757-1759. https://doi.org/10.1002/sim.3887
#'
#'Zou, G.Y. and Donner, A. (2008) Construction of confidence limits about effect measures: a general approach. Stat. Med. 27, 1693–1702. https://doi.org/10.1002/sim.3095
#'Zou, G.Y. and Donner, A. (2008) Construction of confidence limits about effect measures: a general approach. Stat. Med. 27, 1693-1702. https://doi.org/10.1002/sim.3095
#'
#'@seealso
#'\code{\link[ratesci:moverci]{ratesci::moverci}} for MOVER method of ratios
Expand Down
2 changes: 1 addition & 1 deletion R/CVC.R
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ CVC <- function(data, max, conf.level, na.rm = FALSE) {
stop("El data.frame debe contener solo valores numericos.")
}

# Detección de valores perdidos
# Deteccion de valores perdidos
if (!na.rm) {
if (any(is.na(data))) {
stop("Valores perdidos detectados. Usa na.omit() primero o establece na.rm=TRUE.")
Expand Down
2 changes: 1 addition & 1 deletion R/CVI.R
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ CVI <- function(data, cut, conf.level, na.rm = FALSE) {
stop("Todas las columnas deben contener datos numericos.")
}

# Detección de valores perdidos
# Deteccion de valores perdidos
if (!na.rm) {
if (any(is.na(data))) {
stop("Valores perdidos detectados. Usa na.omit() primero o establece na.rm=TRUE.")
Expand Down
6 changes: 3 additions & 3 deletions R/CVIpub.R
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
#' When \code{correct = TRUE}, the function computes the adjusted coefficient \code{CVI.R}
#' and applies the Wilson method to its absolute value. For computational stability,
#' CVI values of exactly 1.0 or 0.0 are replaced by 0.9999 and 0.0001 respectively.
#' If an extreme negative value of CVI.R is detected (e.g., from CVI ≈ 0), the value is
#' If an extreme negative value of CVI.R is detected (e.g., from CVI ? 0), the value is
#' truncated to 0 and the confidence interval is not estimated.
#'
#' @param cvi Numeric vector of CVI values (between 0 and 1).
Expand Down Expand Up @@ -58,7 +58,7 @@ CVIpub <- function(cvi, n, conf.level = 0.95, item.names = NULL, correct = FALSE
if (correct) {
A <- round(cvi.safe[i] * n[i])

# Cálculo estable usando log-factorial
# Calculo estable usando log-factorial
log_pc <- lchoose(n[i], A) + n[i] * log(0.5)
Pc <- exp(log_pc)

Expand All @@ -69,7 +69,7 @@ CVIpub <- function(cvi, n, conf.level = 0.95, item.names = NULL, correct = FALSE
cvir <- 0
lwr[i] <- upr[i] <- NA
if (!truncation_reported) {
message("Extreme negative CVI.R value detected (CVI ≈ 0). Truncated to 0; confidence interval not estimated.")
message("Extreme negative CVI.R value detected (CVI ? 0). Truncated to 0; confidence interval not estimated.")
truncation_reported <- TRUE
}
} else {
Expand Down
4 changes: 2 additions & 2 deletions R/CVR.R
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
#'Note: The function has not yet been prepared to resolve missing values, so the user must remove or impute any missing values.
#'
#'@references
#'Lawshe, C. H. (1975). A quantitative approach to content validity. Personnel psychology, 28, 563–575. https://doi.org/10.1111/j.1744-6570.1975.tb01393.x
#'Lawshe, C. H. (1975). A quantitative approach to content validity. Personnel psychology, 28, 563-575. https://doi.org/10.1111/j.1744-6570.1975.tb01393.x
#'
#'Martuza, V.R. (1977). Applying norm-referenced and criterion-referenced measurement in education. Boston: Allyn & Bacon
#'
Expand All @@ -37,7 +37,7 @@
#'@export
CVR <- function(data, na.rm = FALSE) {

# Detección de valores perdidos
# Deteccion de valores perdidos
if (!na.rm) {
if (any(is.na(data))) {
stop("Valores perdidos detectados. Usa na.omit() primero o establece na.rm=TRUE.")
Expand Down
8 changes: 4 additions & 4 deletions R/CVRcut.R
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,13 @@
#' - \strong{Bag method}: Bayesian method proposed by Baghestani (1993), with prior selection.
#'
#' @references
#' Lawshe, C. H. (1975). A quantitative approach to content validity. *Personnel Psychology*, 28(4), 563–575. https://doi.org/10.1111/j.1744-6570.1975.tb01393.x
#' Lawshe, C. H. (1975). A quantitative approach to content validity. *Personnel Psychology*, 28(4), 563-575. https://doi.org/10.1111/j.1744-6570.1975.tb01393.x
#'
#' Ayre, C., & Scally, A. J. (2014). Critical Values for Lawshe’s Content Validity Ratio: Revisiting the Original Methods of Calculation. *Measurement and Evaluation in Counseling and Development*, 47(1), 79–86. https://doi.org/10.1177/0748175613513808
#' Ayre, C., & Scally, A. J. (2014). Critical Values for Lawshe's Content Validity Ratio: Revisiting the Original Methods of Calculation. *Measurement and Evaluation in Counseling and Development*, 47(1), 79-86. https://doi.org/10.1177/0748175613513808
#'
#' Baghestani, A. R., Ahmadi, F., Tanha, A., & Meshkat, M. (2017). Bayesian Critical Values for Lawshe’s Content Validity Ratio. *Measurement and Evaluation in Counseling and Development*, 52(1), 69–73. https://doi.org/10.1080/07481756.2017.1308227
#' Baghestani, A. R., Ahmadi, F., Tanha, A., & Meshkat, M. (2017). Bayesian Critical Values for Lawshe's Content Validity Ratio. *Measurement and Evaluation in Counseling and Development*, 52(1), 69-73. https://doi.org/10.1080/07481756.2017.1308227
#'
#' Wilson, F. R., Pan, W., & Schumsky, D. A. (2012). Recalculation of the Critical Values for Lawshe’s Content Validity Ratio. *Measurement and Evaluation in Counseling and Development*, 45(3), 197–210. https://doi.org/10.1177/0748175612440286
#' Wilson, F. R., Pan, W., & Schumsky, D. A. (2012). Recalculation of the Critical Values for Lawshe's Content Validity Ratio. *Measurement and Evaluation in Counseling and Development*, 45(3), 197-210. https://doi.org/10.1177/0748175612440286
#'
#' @seealso [CVRcut.Wilson()], [CVRcut.Ayres()], [CVRcut.Bag()]
#'
Expand Down
6 changes: 3 additions & 3 deletions R/CVRcutAyres.R
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#' @title Critical value for CVR, based on Ayres & Scally (2014)
#' @description Calculates critical values for Lawshe’s content validity ratio (CVR) using the method
#' @description Calculates critical values for Lawshe's content validity ratio (CVR) using the method
#' proposed by Ayres & Scally (2014), based on exact binomial probabilities.
#' @param num_jueces Number of judges who provided their ratings (must be >= 2).
#' @param alpha Significance level for the critical value calculation (default: 0.05).
Expand All @@ -22,9 +22,9 @@
#' tests.
#'
#' @references
#' Ayres, C., & Scally, A. J. (2014). Critical values for Lawshe's content validity ratio. Measurement and Evaluation in Counseling and Development, 47, 79–86. https://doi.org/10.1177/0748175613513808
#' Ayres, C., & Scally, A. J. (2014). Critical values for Lawshe's content validity ratio. Measurement and Evaluation in Counseling and Development, 47, 79-86. https://doi.org/10.1177/0748175613513808
#'
#' Lawshe, C. H. (1975). A quantitative approach to content validity. Personnel psychology, 28, 563–575. https://doi.org/10.1111/j.1744-6570.1975.tb01393.x
#' Lawshe, C. H. (1975). A quantitative approach to content validity. Personnel psychology, 28, 563-575. https://doi.org/10.1111/j.1744-6570.1975.tb01393.x
#'
#'@seealso
#'\code{\link[ValCont:CVR]{ValCont::CVR}}
Expand Down
2 changes: 1 addition & 1 deletion R/CVRcutWilson.R
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ CVRcut.Wilson <- function(num_jueces, alpha = 0.05, tails = "one") {
z_alpha <- stats::qnorm(1 - alpha / 2)
}

# Calcular CVR crítico y numero minimo de jueces
# Calcular CVR critico y numero minimo de jueces
cutoff <- round(z_alpha / sqrt(num_jueces), 3)
min_jueces <- ceiling(z_alpha * sqrt(num_jueces / 2) + num_jueces / 2)

Expand Down
4 changes: 2 additions & 2 deletions R/CVplot.R
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
#' \strong{Note}: The function has not yet been prepared to resolve missing values, so the user must remove or impute any `NA`s before plotting.
#'
#' @references
#' Hink, J. K., Wogalter, M. S., & Eustace, J. K. (1996). Display of Quantitative Information: Are Grables better than Plain Graphs or Tables? *Proceedings of the Human Factors and Ergonomics Society Annual Meeting*, 40(23), 1155–1159. https://doi.org/10.1177/154193129604002302
#' Hink, J. K., Wogalter, M. S., & Eustace, J. K. (1996). Display of Quantitative Information: Are Grables better than Plain Graphs or Tables? *Proceedings of the Human Factors and Ergonomics Society Annual Meeting*, 40(23), 1155-1159. https://doi.org/10.1177/154193129604002302
#'
#' Tufte, E. R. (2001). *The Visual Display of Quantitative Information*. Cheshire, CT: Graphics Press.
#'
Expand Down Expand Up @@ -65,7 +65,7 @@ CVplot <- function(data, item.col, point.coeficient, lwr.ci, up.ci,
rotate.x.labels = FALSE,
na.rm = FALSE) {

# Detección de valores perdidos
# Deteccion de valores perdidos
if (!na.rm) {
if (any(is.na(data))) {
stop("Valores perdidos detectados. Usa na.omit() primero o establece na.rm=TRUE.")
Expand Down
4 changes: 2 additions & 2 deletions R/D2.R
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,12 @@
#'
#' @references
#' Aiken, L. R., & Aiken, T. A. (1986). Difference Tests for Distributions of Ratings.
#' Educational and Psychological Measurement, 46(4), 871–881. https://doi.org/10.1177/001316448604600407
#' Educational and Psychological Measurement, 46(4), 871-881. https://doi.org/10.1177/001316448604600407
#'
#' Rosenthal, R. (1991). Meta-analytic procedures for social research (revised). Sage: Newbury Park, CA.
#'
#' Bishara, A. J., & Hittner, J. B. (2017). Confidence intervals for correlations when data are not normal.
#' Behavior Research Methods, 49(1), 294–309. https://doi.org/10.3758/s13428-016-0702-8
#' Behavior Research Methods, 49(1), 294-309. https://doi.org/10.3758/s13428-016-0702-8
#'
#' @examples
#'
Expand Down
4 changes: 2 additions & 2 deletions R/HAiken.R
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
#'
#'Aiken, L. R. (1985). Three coefficients for analyzing the reliability and validity of ratings. Educational and Psychological Measurement, 45, 131-142. https://doi.org/10.1177/0013164485451012
#'
#'Penfield, R. D., & Miller, J. M. (2004). Improving Content Validation Studies Using an Asymmetric Confidence Interval for the Mean of Expert Ratings. Applied Measurement in Education, 17(4), 359–370. https://doi.org/10.1207/s15324818ame1704_2
#'Penfield, R. D., & Miller, J. M. (2004). Improving Content Validation Studies Using an Asymmetric Confidence Interval for the Mean of Expert Ratings. Applied Measurement in Education, 17(4), 359-370. https://doi.org/10.1207/s15324818ame1704_2
#'
#'Wilson, E. B. (1927). Probable inference, the law of succession, and statistical inference. Journal of the American Statistical Association, 22, 209-212. https://doi.org/10.2307/2276774
#'
Expand Down Expand Up @@ -60,7 +60,7 @@
#'@export
Haiken <- function(data, ncat, conf.level, na.rm = FALSE) {

# Detección de valores perdidos
# Deteccion de valores perdidos
if (!na.rm) {
if (any(is.na(data))) {
stop("Valores perdidos detectados. Usa na.omit() primero o establece na.rm=TRUE.")
Expand Down
14 changes: 7 additions & 7 deletions R/HT.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#' Hinkin–Tracey Content Validity Indices for Multiple Items
#' Hinkin-Tracey Content Validity Indices for Multiple Items
#'
#' @description
#' Computes Hinkin and Tracey (1999) content validity indices for multiple items
Expand All @@ -20,7 +20,7 @@
#' and then rescaled to the \code{htc}/\code{htd} metrics.
#'
#' @param data A data frame or matrix in wide format, where each column
#' corresponds to one item–construct combination. Columns are expected
#' corresponds to one item-construct combination. Columns are expected
#' to follow the pattern \code{"item.construct"}, e.g.,
#' \code{"item1.c1"}, \code{"item1.c2"}, \code{"item1.c3"}.
#' @param items Character vector with the base names of the items to be
Expand Down Expand Up @@ -116,29 +116,29 @@
#' \code{item}, \code{target}, \code{nj}, and the construct means
#' (\code{M.<construct>} columns).}
#' \item{\code{Item.criteria}}{A data frame with one row per item,
#' containing the global Hinkin–Tracey indices:
#' containing the global Hinkin-Tracey indices:
#' \code{item}, \code{htc}, \code{htc.lci}, \code{htc.uci},
#' \code{htd}, \code{htd.lci}, \code{htd.uci}. If \code{ci = FALSE},
#' the confidence interval columns are filled with \code{NA}.}
#' \item{\code{Pairwise.criteria}}{A data frame in long format, with one
#' row per item–orbiting construct combination, containing:
#' row per item-orbiting construct combination, containing:
#' \code{item}, \code{target}, \code{orbiting}, \code{htd},
#' \code{htd.lci}, \code{htd.uci}. If \code{ci = FALSE}, the confidence
#' interval columns are filled with \code{NA}.}
#' }
#'
#' @references
#' Hinkin, T. R., & Tracey, J. B. (1999). An analysis of variance approach
#' to content validation. \emph{Organizational Research Methods, 2}(2), 175–186.
#' to content validation. \emph{Organizational Research Methods, 2}(2), 175-186.
#'
#' Colquitt, J. A., Sabey, T. B., Rodell, J. B., & Hill, E. T. (2019).
#' Content validation guidelines: Evaluation criteria for definitional
#' correspondence and definitional distinctiveness. \emph{Journal of Applied
#' Psychology, 104}(10), 1243–1265.
#' Psychology, 104}(10), 1243-1265.
#'
#' Penfield, R. D., & Miller, J. M. (2004). Improving content validation
#' studies using an asymmetric confidence interval for the mean of expert
#' ratings. \emph{Applied Measurement in Education, 17}(4), 359–370.
#' ratings. \emph{Applied Measurement in Education, 17}(4), 359-370.
#'
#' @examples
#' \dontrun{
Expand Down
2 changes: 1 addition & 1 deletion R/LuAgree.R
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@
#' \item \code{n_subjects} Number of subjects used in the analysis.
#' \item \code{n_judges} Number of judges.
#' \item \code{categories} The ordered rating categories used.
#' \item \code{p_empirical} Empirical category probabilities (información
#' \item \code{p_empirical} Empirical category probabilities (informacion
#' auxiliar; no se imprime por defecto).
#' \item \code{call} The matched function call.
#' }
Expand Down
Loading
Loading