cronbach_alpha(
...,
data,
var_name,
group = NULL,
quite = FALSE,
return_result = FALSE
)
Items. Group each latent factors using c() with when computing Cronbach alpha for 2+ factors (see example below)
data.frame
. Must specify
character or a vector of characters. The order of var_name
must be same as the order of the ...
optional character. Specify this argument for computing Cronbach alpha for group separetely
suppress printing output
If it is set to TRUE
, it will return a dataframe
object
a data.frame
object if return_result is TRUE
cronbach_alpha(
data = lavaan::HolzingerSwineford1939,
var_name = c('Visual','Textual','Speed'),
c(x1,x2,x3), # one way to pass the items of a factor is by wrapping it with c()
x4:x6, # another way to pass the items is use tidyselect syntax
x7:x9)
#> Number of categories should be increased in order to count frequencies.
#> Number of categories should be increased in order to count frequencies.
#> Number of categories should be increased in order to count frequencies.
#> Number of categories should be increased in order to count frequencies.
#> Number of categories should be increased in order to count frequencies.
#> Number of categories should be increased in order to count frequencies.
#>
#>
#> Model Summary
#> Model Type = Cronbach Alpha Reliability Analysis
#> Model Specification:
#> Visual = x1 + x2 + x3
#> Textual = x4 + x5 + x6
#> Speed = x7 + x8 + x9
#>
#> ───────────────────────────────
#> Var raw_alpha std_alpha
#> ───────────────────────────────
#> Visual 0.626 0.627
#> Textual 0.883 0.885
#> Speed 0.688 0.690
#> ───────────────────────────────
#>