data(dichodata)
data(dichokey)
# Data preparation
## Corrected data
corr <- correct(x = dichodata, key = dichokey, navalue = NA)
## Random weights creation
set.seed(1919)
wt <- sample(x = 1:4, size = nrow(corr), replace = TRUE)
# Correlations without weights
pointbiserial(x = corr, wt = NULL)
# Correlations with weights
pointbiserial(x = corr, wt = wt)
# Correlations if item is excluded
pointbiserial(x = corr, exclude = TRUE)
# Correlations if NAs are considered 0s (recScore)
pointbiserial(x = corr, recScore = FALSE)
# Correlations with listwise
pointbiserial(x = corr, listwise = TRUE)
Run the code above in your browser using DataLab