Closed mahendra-mariadassou closed 10 months ago
Open question for @jchiquet : should we return and as attributes of the predictions (like we do for predict_cond() ? I think there's not a lot of added value compared to using optimize_vestep() if one is mostly interested in M and S but you may have a different opinion.
I agree with you, no need to send back M or S as attributes.
Fix #114 by changing behavior of
predict()
method (and corresponding S3-methods) for PLNfit objects:newdata
argument is missing, returns fittednewdata
is provided but notresponses
, returns either $EZ = XB + O
$ (link
type) or $EZ = exp(XB + O + 0.5\text{diag}(\Sigma))
$ (response
type) as the best estimates of $M_{new}
$ and $S_{new}
$ are then 0 and $\text{diag}(\Sigma)
$responses
is also provided, performs one VE step to estimate $M_{new}
$ and $S_{new}
$ and returns either $EZ = XB + O + M_{new}
$ (link
type) or $EZ = exp(XB + O + M_{new} + 0.5 S_{new})
$ (response
type)Open question for @jchiquet : should we return $
M_{new}
$ and $S_{new}
$ as attributes of the predictions (like we do forpredict_cond()
? I think there's not a lot of added value compared to usingoptimize_vestep()
if one is mostly interested in M and S but you may have a different opinion.