strel {Bayesrel}R Documentation

calculate single test reliability estimates

Description

calculate Bayesian and frequentist single test reliability measures. Reported are Bayesian credible intervals (HDI) and frequentist confidence intervals (non parametric or parametric bootstrap). The estimates supported are Cronbach alpha, lambda2/4/6, the glb, and Mcdonald omega. Beware of lambda4 with many indicators, the computational effort is considerable

Usage

strel(
  data = NULL,
  estimates = c("alpha", "lambda2", "glb", "omega"),
  cov.mat = NULL,
  interval = 0.95,
  n.iter = 1000,
  n.burnin = 50,
  thin = 1,
  n.chains = 3,
  n.boot = 1000,
  omega.freq.method = "cfa",
  n.obs = NULL,
  alpha.int.analytic = TRUE,
  omega.int.analytic = TRUE,
  freq = TRUE,
  Bayes = TRUE,
  para.boot = FALSE,
  item.dropped = FALSE,
  missing = "pairwise",
  callback = function() { }
)

Arguments

data

The dataset to be analyzed, observations are rows, items are columns

estimates

A character vector containing the estimands, we recommend using lambda4 with only a few items due to the computation time

cov.mat

A covariance matrix can be supplied instead of a dataset, but number of observations needs to be specified

interval

A number specifying the uncertainty interval

n.iter

A number for the iterations of the Gibbs Sampler

n.burnin

A number for the burnin in the Gibbs Sampler

thin

A number for the thinning of the MCMC samples

n.chains

A number for the chains to run for the MCMC sampling

n.boot

A number for the bootstrap samples

omega.freq.method

A character string for the method of frequentist omega, either "pfa" or "cfa", with "pfa" the interval is always bootstrapped

n.obs

A number for the sample observations when a covariance matrix is supplied and the factor model is calculated

alpha.int.analytic

A logical for calculating the alpha confidence interval analytically

omega.int.analytic

A logical for calculating the omega confidence interval analytically, only works with cfa as the omega.freq.method

freq

A logical for calculating the frequentist estimates

Bayes

A logical for calculating the Bayesian estimates

para.boot

A logical for calculating the parametric bootstrap, the default is the non-parametric

item.dropped

A logical for calculating the if-item-dropped statistics

missing

A string specifying the way to handle missing data, 'listwise' is self-explanatory, 'pairwise' in the Bayesian paradigm means sampling the missing values as additional parameters from the joint conditional distribution, in the frequentist paradigm this means using the 'pairwise' covariance matrix and the full information ML method for omega

callback

step count for external use

References

Murphy KP (2007). “Conjugate Bayesian analysis of the Gaussian distribution.” University of British Columbia. Lee S (2007). Structural equation modeling: A Bayesian approach, volume 711. John Wiley \& Sons.

Examples

summary(strel(asrm, estimates = "lambda2", n.chains = 2, n.iter = 200, n.boot = 200))
summary(strel(asrm, estimates = "lambda2", item.dropped = TRUE, n.chains = 2,
n.iter = 100, n.boot = 200))



[Package Bayesrel version 0.7.0.7 Index]