Help file for the command rrisk ---------------------------------Syntax ------
rrisk , cmd( logistic regression command here )
The rrisk command computes relative risks for 0/1 predictor variables given in the logistic regression command in the cmd( ) option. Variables which are not coded 0/1 are overlooked for this computation.
For a given variable (say X) the relative risk is computed by obtaining the predicted probability that Y=1 when X is 1 and the predicted probabily that Y=1 when X=0. These predicted probabilities are divided and then summarized, yielding the relative risk.
Examples --------
use https://stats.idre.ucla.edu/stat/stata/notes/hsb2, clear gen goodread = read > 60 gen public = schtyp == 1
* example 1, just get rr rrisk, cmd(logistic goodread female public write)
* example 2, use "bs" to get rr for female bs "rrisk, cmd(logistic goodread female public write)" "r(rr_female)", reps(100 > 0)
* example 3, use "bs" to get rr for female and public bs "rrisk, cmd(logistic goodread female public write)" "r(rr_female) r(rr_publi > c)", reps(1000)
Author ------ Michael N. Mitchell (Based on a program by Susan Ettner) Statistical Computing and Consulting UCLA Academic Technology Services mnmatucla.edu