-
Notifications
You must be signed in to change notification settings - Fork 303
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unexpected behaviour in augment() for person residuals. #1147
Comments
Thanks for the detailed reprex! Agreed that this is an issue. I missed this in #965. Rather than touching that helper, I may just overwrite its Lines 90 to 98 in dc14b10
|
Thanks, yes, that will likely fix this. |
This issue has been automatically locked. If you believe you have found a related problem, please file a new issue (with a reprex: https://reprex.tidyverse.org) and link to this issue. |
The problem
I was trying the
augment(fit)
function usingtype.residuals = "pearson"
and found the output of column.std.resid
to be different to that ofrstandard(fit, type = "pearson")
.After some digging, it seems the issue is introduced by function
add_hat_sigma_cols
broom/R/utilities.R
Line 374 in 60da694
This issue is inconsequential for family = gaussian but has some implications for any other family member and that's probably why simple testing may have passed.
So, in essence, column
.std.resid
always contains standardized deviance residuals irrespective of the argumenttype.residuals
, which I believe is not the expected behaviour.Reproducible example
Created on 2023-03-07 with reprex v2.0.2
Session info
The text was updated successfully, but these errors were encountered: