Skip to contents

Ordering is incremental patterns of power 2 from right to left.

Usage

create_resp_pattern(p = 3)

Arguments

p

(integer > 0) The number of items.

Value

A tibble() containing ordinal binary values (0/1) for the items as well as a column indicating one of the \(2^p\) response patterns.

Examples

create_resp_pattern(p = 3)
#> # A tibble: 8 × 4
#>   y1    y2    y3    pattern
#>   <ord> <ord> <ord> <chr>  
#> 1 1     1     1     111    
#> 2 1     1     0     110    
#> 3 1     0     1     101    
#> 4 1     0     0     100    
#> 5 0     1     1     011    
#> 6 0     1     0     010    
#> 7 0     0     1     001    
#> 8 0     0     0     000