nice_agreement_table: Perform within agreement analysis

View source: R/nice_agreement_analysis.R

nice_agreement_tableR Documentation

Perform within agreement analysis

Description

This function performs an agreement analysis including intra-class correlation coefficients, group-related variance, and related diagnostics for items with a nominal or ordinal scale. The function outputs a data.frame or a HTML table giving the results.

Usage

nice_agreement_table(
  data,
  vars = names(data),
  grouping,
  rv,
  crit = 0.7,
  min_group_size = NULL,
  auto_labels = TRUE,
  labels = NULL,
  n_sim = 10000
)

Arguments

data

A data-frame

vars

Vector of character strings with names of variables to be analyzed.

grouping

Grouping variable. Either as a character string or a vector.

rv

Number of response options for calculating random variance.

crit

Critical agreement level.

min_group_size

Minimal group size. Smaller groups are excluded.

auto_labels

If TRUE, variable names are taken from a label attribute.

labels

Character vector with new variable labels.

n_sim

Number of simulations for the agreement analyses.

Value

A Data-frame

Examples


vars <- c("Norm_Pop_academic", "Norm_Pop_conform", "Norm_Pop_sporty",
  "Norm_Pop_cool_clothes", "Norm_Pop_helpful", "Norm_Unpop_academic",
  "Norm_Unpop_nonconform", "Norm_Unpop_sporty", "Norm_Unpop_cool_clothes",
  "Norm_Unpop_language", "Norm_LM_academic", "Norm_LM_conform",
  "Norm_LM_sporty", "Norm_LM_cool_clothes", "Norm_LM_helpful",
  "Norm_LL_academic", "Norm_LL_nonconform", "Norm_LL_sporty", "Norm_LL_cool_clothes",
  "Norm_LL_language")

nice_agreement_table(
    data = wmisc:::ex_agreement,
    vars = vars,
    grouping = "id_class_teacher",
    rv = 4,
    crit = 0.6,
    n_sim = 100)

jazznbass/wmisc documentation built on Oct. 29, 2024, 5:42 p.m.