poissonconsulting / extras

An R package of helper functions for Bayesian analyses
https://poissonconsulting.github.io/extras/
Other
9 stars 2 forks source link

Check again whether multinomial residuals are possible #62

Open nehill197 opened 3 months ago

nehill197 commented 3 months ago

See if this post has any validity https://stats.stackexchange.com/questions/186560/what-is-multinomial-deviance-in-the-glmnet-package

nehill197 commented 1 month ago

Started working on this and was able to validate the deviance calculation by comparing to the output of a VGAM::vglm() model.

We need to figure out if each row modelled by a multinomial should have a single deviance value or one for each column in that row.

This may require an "extended" way to calculate the sign for the deviance residuals (i.e., it isn't as simple as taking the sign of a single value). There is a method to do this detailed here (https://convegni.unica.it/cladag2015/files/2015/10/Romeo1.pdf), however I find it unclear.

joethorley commented 1 month ago

This might also be worth a read:

https://onlinelibrary.wiley.com/doi/full/10.1002/sam.11645