AWG: AWG: Agreement Within-Groups

View source: R/AWG.R

AWGR Documentation

AWG: Agreement Within-Groups

Description

This function estimates Brown & Hauenstein's (2005) within-group agreement statistic. For a single item the statistic is denoted awg. For a scaled based on J items, the statistic is denoted awg.j.

Usage

AWG(x, grpid, model, scale)

Arguments

x

Either a vector representing a single item used to estimate awg or a matrix representing a set of items used to estimate awg.j.

grpid

Grouping/clustering variable

model

User-supplied description of multilevel measurement model (e.g., consensus)

scale

A vector containing the lowest and highest response options on the scale.

Details

The input consists of the item(s), the grouping or clustering variable, a description of the multilevel measurement model used to aggregate the data (e.g., additive, consensus), and the low and high values of the response scale.

The output consists of a list containing: a) descriptive statistics summarizing the results across all of the groups, b) a data frame containing the group names, group sizes, and the group-level estimates of awg/awg.j, and c) a histogram plotting the distribution of awg/awg.j values.

Link to Brown and Hauenstein:

Value

List containing a matrix of the null error values, estimates of RWG, and summary of how many negative values were obtained

Examples

data(lq2002, package = "multilevel")
AWG(x=lq2002[,c(3)], grpid = lq2002$COMPID, model = "Consensus", scale=c(1,5))

james-lebreton/WGA documentation built on Oct. 17, 2022, 4:05 a.m.