Reduce the size of an lx_model by compressing posterior draws and/or
dropping optional components. Public and private draws are always kept,
but can be subsampled or averaged. By default no draw compression is
applied, but simulated answers are still dropped, which can be useful
when you don't need them.
Arguments
- model
An object of class
lx_model.- compress
How to compress draws.
"subsample"keeps a subset of draws;"mean"replaces draws with per-respondent posterior means (1 column).- size
For
compress = "subsample", controls how many draws to keep. Ifsizeis in(0, 1], it is treated as a fraction of draws to keep. Ifsizeis> 1, it is treated as a count of draws to keep. Default is1(keep all draws).- method
When subsampling, how to pick draws.
"even"selects evenly spaced draws;"random"samples draws without replacement.- seed
Optional integer seed used for random subsampling.
- drop_sim
Logical. If
TRUE, drop simulated responses (sim_public,sim_private).- drop_responses
Logical. If
TRUE, drop observed responses (response_public,response_private,response_majority).- drop_diagnostics
Logical. If
TRUE, dropdraws_summaryandrhat_summary.