【发布时间】:2020-12-02 18:04:25
【问题描述】:
我正在尝试计算 5 个不同调查问题的索引的 Cronbach alpha。它们的比例相同,0-10。我用变量创建了一个矩阵
我有 47000 次观察,所以问题不是由于缺乏观察。当我使用 psych 软件包时,我得到的信息比我预期的要少。
trust_alpha <- alpha(x = trust_ma)
trust_alpha
输出是:
Number of categories should be increased in order to count frequencies.
Reliability analysis
Call: alpha(x = trust_ma)
lower alpha upper 95% confidence boundaries
0.89 0.9 0.9
Reliability if an item is dropped:
Item statistics
我无法弄清楚“应增加类别数以计算频率”。意味着,以及为什么我在丢弃物品或物品统计信息时无法获得可靠性。 有没有办法,我可以得到这些信息?
非常感谢您提供的任何帮助。
编辑
使用 dput(head(trust)) 概览数据
structure(list(idno = c(27L, 137L, 194L, 208L, 220L, 254L), trstplt = c(5L,
3L, 5L, 3L, 7L, 5L), trstprt = c(5L, 4L, 5L, 3L, 7L, 5L), trstprl = c(5L,
7L, 6L, 0L, 7L, 6L), trstplc = c(10L, 8L, 8L, 8L, 8L, 7L), trstlgl = c(10L,
8L, 8L, 5L, 8L, 5L), trust_norris = c(7, 6, 6.4, 3.8, 7.4, 5.6
), trust_norris_na = c(0L, 0L, 0L, 0L, 0L, 0L)), row.names = c(NA,
-6L), groups = structure(list(.rows = structure(list(1L, 2L,
3L, 4L, 5L, 6L), ptype = integer(0), class = c("vctrs_list_of",
"vctrs_vctr", "list"))), row.names = c(NA, -6L), class = c("tbl_df",
"tbl", "data.frame")), class = c("rowwise_df", "tbl_df", "tbl",
"data.frame"))
带头(信任)
head(trust)
# A tibble: 6 x 8
# Rowwise:
idno trstplt trstprt trstprl trstplc trstlgl trust_norris trust_norris_na
<int> <int> <int> <int> <int> <int> <dbl> <int>
1 27 5 5 5 10 10 7 0
2 137 3 4 7 8 8 6 0
3 194 5 5 6 8 8 6.4 0
4 208 3 3 0 8 5 3.8 0
5 220 7 7 7 8 8 7.4 0
6 254 5 5 6 7 5 5.6 0
idno 是我的 ID 变量,因为它是更大数据集的子集,trust_norris 是反射指数,即 trstplt、trstprt、trstprl、trstplc 和 trstlgl 的平均值。 trust_norris_na 是一个变量,描述了 trstplt、trstprt、trstprl、trstplc 和 trstlgl pr 中有多少 NA。行。
我创建了一个相关变量的矩阵
trust_ma <- data.matrix(subset(trust, select = c(trstplt, trstprt, trstprl, trstplc, trstlgl)))
【问题讨论】:
-
如果你能分享一些你的数据会很有帮助。请编辑您的问题并添加
dput(head(trust))的结果。我知道如果数据是用dplyr操作的,或者如果采用与数据框或矩阵不同的类,可能会出现问题。但可以肯定的是,重现所获得的问题会很棒。