Skip to contents

A single call for synpmx_model_estimate() followed by synpmx_model_generate(). Use the two separately to look at the fit before generating from it. The result carries the fit's model_fingerprint() as its pmx_fitted_model attribute, which is what generation read; the candidate table, the starting values and the other diagnostics are only on the fit itself.

Usage

synpmx_model(data, roles, n_subjects = NULL, seed = NULL, ...)

Arguments

data

Source PMX event data.

roles

Explicit column roles from pmx_roles(), including nominal_time.

n_subjects

Number of synthetic subjects. Defaults to the source count.

seed

Seed, used for both stages.

...

Passed to synpmx_model_estimate(), including min_category_patients (default 3). Set it to 1 to retain all observed categorical baseline levels.

Value

A data frame in the source's shape, carrying the fitted model's fingerprint as an attribute.