Learn R Programming

ldamatch (version 0.6.3)

search_heuristic: At each vertex of the search graph, this takes a step which moves the proportions of conditions in the subspace closer to the desired (or sample) proportions.

Description

At each vertex of the search graph, this takes a step which moves the proportions of conditions in the subspace closer to the desired (or sample) proportions.

Usage

search_heuristic(sspace, condition, covariates, halting_test, thresh, props)

Arguments

sspace
An ordered subject subspace: a list of vectors, with one vector per group containing the corresponding subject indices.
condition
A factor vector containing condition labels.
covariates
A vector or columnwise matrix containing covariates to match the conditions on.
halting_test
A function to apply to `covariates` (in matrix form) which is TRUE iff the conditions are matched.
thresh
The statistical threshold to pass onto the aforementioned test.
props
The desired proportions (percentage) of the sample for each condition; if not specified, the (full) sample proportions are used. This is used for the "heuristic" and "exhaustive" methods.