You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
How to estimate risk ratio/risk difference? I did a quick search.
risk ratio: looks like log link doesn't work? i.e. family = binomial(link = "log))
instead uses poisson with log link and find standard error via sandwich package/bootstrap
see: https://ai-abdelaziz.com/posts/risk-ratio-regression/
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
How to estimate risk ratio/risk difference? I did a quick search.
risk ratio: looks like log link doesn't work? i.e. family = binomial(link = "log))
instead uses poisson with log link and find standard error via sandwich package/bootstrap
see: https://ai-abdelaziz.com/posts/risk-ratio-regression/
risk difference: looks like you fit a regular logistic regression with logit link, predict the probabilities and subtract them.. standard error is found by bootstrap
see: https://www.r-bloggers.com/2021/06/estimating-a-risk-difference-and-confidence-intervals-using-logistic-regression/
Alternate way to calculate is maybe via using marginaleffects library
see: https://stats.stackexchange.com/questions/606524/calculate-risk-ratio-with-ci-in-r-from-odds-ratios
There seems to be even a R package called risks that does this..
see: https://cran.r-project.org/web/packages/risks/risks.pdf
Beta Was this translation helpful? Give feedback.
All reactions