Skip to contents

S3 configuration object for conjoint design generation workflows.

Usage

cjtd_design_config(
  attributes,
  n_tasks = NULL,
  n_alternatives = NULL,
  n_versions = NULL
)

Arguments

attributes

Named list of attribute level vectors.

n_tasks

Optional scalar positive integer. Defaults to NULL.

n_alternatives

Optional scalar positive integer. Defaults to NULL.

n_versions

Optional scalar positive integer. Defaults to NULL.

Value

An object of class cjtd_design_config.

Examples

# Start by defining the attribute space.
cfg <- cjtd_design_config(
  attributes = list(
    brand = c("A", "B", "C", "D"),
    price = c("very_high", "high", "mid", "low", "very_low"),
    f1 = c("off", "on"),
    f2 = c("off", "on"),
    f3 = c("off", "on")
  ),
  n_tasks = 10,
  n_alternatives = 3,
  n_versions = 2
)

cfg
#> 
#> ── Conjoint Design Config ──────────────────────────────────────────────────────
#> • n_tasks: 10
#> • n_alternatives: 3
#> • n_versions: 2
#> • restrictions: 0
#> attributes:
#> brand: A, B, C, D
#> price: very_high, high, mid, low, very_low
#> f1: off, on
#> f2: off, on
#> f3: off, on
#> ────────────────────────────────────────────────────────────────────────────────