bws.questionnaire: Converting a two-level OMED/BIBD into BWS questions

View source: R/bws.questionnaire.R

bws.questionnaireR Documentation

Converting a two-level OMED/BIBD into BWS questions

Description

This function converts a two-level orthogonal main-effect design (OMED)/balanced incomplete block design (BIBD) into a series of BWS questions.

Usage

bws.questionnaire(choice.sets, design.type, item.names)

Arguments

choice.sets

A data frame or matrix containing choice sets.

design.type

A value describing how to design the choice sets: 1 if the design assigned to choice.sets is a two-level OMED, and 2 if it is a BIBD.

item.names

A vector containing the names of items shown in the questions.

Details

A two-level OMED/BIBD is assigned to choice.sets, and may be generated by R functions (e.g., the oa.design function in DoE.base; the find.BIB function in crossdes) or copied manually from text books/web sites related to the design of experiments.

When the design is a two-level OMED, each row corresponds to a question and each column corresponds to an item. The level values in the design have to be 1 and 2. The former corresponds to an item being “absent” from a column and the latter corresponds to the item being “present.” The correspondence between item names and columns is defined and assigned to the argument item.names: the order of names in the vector assigned to item.names corresponds to the order of columns (from left to right) in the choice sets assigned to choice.sets.

When the design is a BIBD, each row corresponds to a question and the number of columns is equal to the number of items per question. The level values in the design have to be serial integer values, starting from 1: each value corresponds to an item. The correspondence between item names and level values is defined and assigned to the argument item.names: the order of names in item.names corresponds to the order of level values in the design (i.e., the j th item in item.names corresponds to the level value of j in the design).

Value

BWS questions converted from the design are returned.

Author(s)

Hideo Aizaki

See Also

bws.dataset, oa.design, find.BIB

Examples

## See examples in bws.dataset()

support.BWS documentation built on March 31, 2023, 8:12 p.m.