count.selections: Count attribute selections

View source: R/tcata.R

count.selectionsR Documentation

Count attribute selections

Description

Count the number of times that the attribute was selected (or optionally: deselected) in a single TCATA or TDS evaluation.

Usage

count.selections(x, deselections = FALSE)

Arguments

x

vector of binary data (with possible values 0 or 1)

deselections

set to TRUE if purpose is to count the number of deselections

Details

Count the number of times that the attribute was selected (or, optionally, deselected) in a single TCATA or TDS evaluation.

Value

count of selections (or deselections if deselections = TRUE)

Examples

data(bars)
paste0(bars[1, -c(1:4)], collapse = "")
# this attribute was checked 3 times and unchecked 2 times
count.selections(bars[1, -c(1:4)])
count.selections(bars[1, -c(1:4)], deselections = TRUE)

tempR documentation built on Sept. 8, 2023, 5:19 p.m.