sample_conditions: Sample synthetic rows that match fixed column values (conditional sampling)
Description
Generates rows in which one or more categorical or boolean columns are
held to specified values, via rejection sampling against the fitted copula.
This preserves the modeled dependence between the conditioned columns and the
rest of the table (unlike overwriting values after the fact).
A data frame of synthetic rows satisfying the conditions.
Arguments
x
A fitted gaussian_copula_synthesizer.
conditions
A data frame whose columns are the variables to fix. Each
row is one condition; an optional integer column .n gives how many rows
to generate for that condition (default 1 per row).