toTallMatrix: Converts 3d array of CATA data to a tall 2d matrix format

View source: R/cata.R

toTallMatrixR Documentation

Converts 3d array of CATA data to a tall 2d matrix format

Description

Converts a three-dimensional array (I assessors, J products, M attributes) to a two-dimensional matrix with (I assessors, J products) rows and (M attributes) columns, optionally preceded by two columns of row headers.

Usage

toTallMatrix(X, header.rows = TRUE)

Arguments

X

three-dimensional array (I assessors, J products, M attributes) where values are 0 (not checked) or 1 (checked)

header.rows

TRUE (default) includes row headers; set to FALSE to exclude these headers

Value

matrix with I assessors \times J products in rows and M attributes in columns (optionally preceded by 2 columns of headers if header.rows = TRUE)

Author(s)

J.C. Castura

Examples

# convert CATA results from the first 8 consumers and the first 4 attributes
# to a tall matrix
toTallMatrix(bread$cata[1:8,,1:4])

cata documentation built on Aug. 1, 2026, 1:06 a.m.

Related to toTallMatrix in cata...