Skip to contents

How many symptom combinations a search will evaluate. With a cluster structure only combinations covering every cluster are candidates, which for six PCL-5 items out of twenty is 13,685 rather than 38,760 – the denominator a plateau proportion has to be read against.

Usage

n_candidates(n_symptoms = 6L, clusters = NULL, n_total = 20L)

Arguments

n_symptoms

Combination size.

clusters

NULL, or a named list of integer vectors.

n_total

Number of items to choose from.

Value

A single integer.

Examples

# Small spaces make the point in milliseconds; the six-symptom equivalents
# are 38,760 and 13,685. A cluster-constrained space needs at least one item
# per cluster, so four is the smallest that exists here.
n_candidates(3)
#> [1] 1140
n_candidates(4, clusters = list(B = 1:5, C = 6:7, D = 8:14, E = 15:20))
#> [1] 420