-
Notifications
You must be signed in to change notification settings - Fork 2
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
Add option to broom
tidiers to standardize parameters
#28
Comments
Maybe |
Apparently, it doesn't have any function that does that (https://discourse.mc-stan.org/t/obtaining-standardized-coefficients-from-rstanarm-package-in-r/3603). |
Could broom itself do the standardization on the posterior samples? Or would that fall outside scope? |
If we are doing stuff on posterior samples, then tidybayes might be better. I think of that as the Bayesian broom. (Sorry Alex 😅.) What would we need to standardize the coefficients? Is there some magic we can do with a variance-covariance matrix? Or do we have to dig inside the model's data/matrix, take the SD of the numeric variables and do Gelman's thing to the binary variables? |
Haha. Yes, the latter sounds about right. Need to think more about the implementation. |
Re: Bayes stuff: totally agree, I haven't really invested any effort into this in If you want to standardize the input data, this is pre If you want to standardize coefficients after the fact, that means going to find the I see the appeal of a |
Additional thought: you might want to standardize after the fact so you could get both the standardized and original scale coefficients without fitting the model twice. Again, |
Standardized regression coefficients are much easier to compare, interpret, visualize, etc. than unstandardized ones. So it'll be nice if
broom
tidiers gain astandardize
argument that decides whether the regression coefficients are to be standardized.Few other packages have tried to do this.
dotwhisker
package uses Gelman's 2SD method:https://www.rdocumentation.org/packages/dotwhisker/versions/0.5.0/topics/by_2sd
(but it falters when interaction terms are present: by_2sd fails with model including interactions and non-standard contrasts fsolt/dotwhisker#82)
arm
package also uses Gelman's method but supports very few models:https://www.rdocumentation.org/packages/arm/versions/1.10-1/topics/standardize
parameters
package (unclear method)https://easystats.github.io/parameters/reference/standardize.lm.html
The text was updated successfully, but these errors were encountered: