I want to distribute a fitted gamlss model (lms) as a file. The data used to fit the gamlss model must not be published, as it is subject to privacy regulations.
However, when I use the save
or saveRDS
functions, the resulting files are both huge and contain the raw data. Removing individual variables, e.g. $y
, from the gamlss model object is possible but does not seem like the correct way to go (and sometimes -depending on the member I drop- results in errors when I use gamlss functions on the modified model).
Is there a better way to distribute/serialize gamlss models that a) does not reveal the underlying data, b) allows use of the gamlss functions, and c) results in smaller files?
(My searches regarding this were unsuccessful, perhaps because of inadequate search terms - if so, a pointer in the right direction would be much appreciated.)
Thanks Jakob