binom_to_multinom {multinomineq}R Documentation

Converts Binary to Multinomial Frequencies

Description

Converts the number of "hits" in the binary choice format to the observed frequencies across for all response categories (i.e., the multinomial format).

Usage

binom_to_multinom(k, n)

Arguments

k

vector of observed response frequencies.

n

the number of choices per item type. If k=n=0, Bayesian inference is relies on the prior distribution only.

Details

In multinomineq, binary choice frequencies are represented by the number of "hits" for each item type/condition (the vector k) and by the total number of responses per item type/condition (the scalar or vector n).

In the multinomial format, the vector k includes all response categories (not only the number of "hits"). This requires to define a vector options, which indicates how many categories belong to one item type/condition (since the total number of responses per item type is fixed).

Examples

k <- c(1, 5, 8, 10)
n <- 10
binom_to_multinom(k, n)


[Package multinomineq version 0.2.6 Index]