cjpwr
carries out very simple power analyses for conjoint designs.
cjpwr()
takes four arguments: n
(sample size), t
(number of choice tasks per respondent), a
(number of alternatives per choice task), and c
(number of analysis cells - equal to largest number of possible levels for any one feature, or the largest product of levels of any two attributes for power of two-way interaction estimates). It simply divides t*n*a
by c
. The output of cjpwr
is a dataframe including the inputs and result of this calculation, whether (yes/no) your design exceeds the minimal minimum threshold (500) and the ideal minimum threshold (1000), and the necessary sample sizes to exceed these thresholds.
cjpwr_data()
does the same thing but a bit more cleverly. It just takes the name of a dataframe, a formula, and a respondent ID variable, and using these it calculates values of n, t, a, and c itself, and gives the same output as cjpwr()
. It uses tidy syntax including magrittr piping, so it requires installation of tidyverse
- GPL-3 licensed.
The calculation is based on recommendations from Orme (2010). Examples in the documentation use datasets from cregg
- MIT licensed.