reshape_incremental_design_into_unique_exposure_test_combinations | R Documentation |
Takes data.frame
or tibble
that contains the exposure and test data from an incremental
exposure-test design in long format, and prepares it for input to the ideal_adaptor_stanfit
Stan programs. This is done by pretending that each incremental test block (and its preceding exposure)
constitute a separate between-participant condition. Note that this does not capture the dependency
between test responses of participants in the same between-participant conditions, but such dependencies
are not modeled by current 'MVBeliefUpdatr' Stan programs anyway (which do not include random effects by
participants).
reshape_incremental_design_into_unique_exposure_test_combinations(
data,
group = "Group",
phase = "Phase",
block = "Block",
join_adjacent_test_blocks = FALSE,
verbose = FALSE
)
data |
Data frame or tibble to be sliced. Each row should be a single exposure or test observation. |
group |
Character string indicating the name of the column that contains the information about the between-participant condition. (default: "Group") |
phase |
Character string indicating the name of the column that contains the information about whether an observation is part of "exposure" or "test". This column must contain the values "exposure" and "test". Observation with other values will be ignored. (default: "Phase") |
block |
Character string indicating the name of the column that contains the information about the incremental exposure and test blocks. Must be a factor with the levels indicating the order of the blocks. (default: "Block") |
join_adjacent_test_blocks |
Logical indicating whether adjacent test blocks without intervening
exposure blocks should be joined into a single test block. This will speed up |
verbose |
Should verbose output be provided? (default: 'FALSE') |
A data frame or tibble in long format with a new column "ExposureGroup" that contains a unique label for each unique combination of 'group' and 'block'.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.