Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • calculate Median odds ratio (MOR)

    Good afternoon, I have a question, I need to calculate median odds ratio in stata (MOR). I saw your post and I do it. But I am not a statistics, and I have a question. If I have to calculate the MOR in a logistic regression multilevel in the coefficients. How can I do?. I don't have a variance.

    I do this: I don't Know what is the variance to calculate in the coefficients, PLEASE I NEED HELP


    . melogit mortalidad edad genero1 ipmTotal ZOMAC PDET afro indigena || codi
    > godivipoladepartamento: || id: , coeflegend

    Fitting fixed-effects model:

    Iteration 0: log likelihood = -889093.63
    Iteration 1: log likelihood = -518135.36
    Iteration 2: log likelihood = -503053.32
    Iteration 3: log likelihood = -502096.46
    Iteration 4: log likelihood = -502095.16
    Iteration 5: log likelihood = -502095.16

    Refining starting values:

    Grid node 0: log likelihood = -498130.58

    Fitting full model:

    Iteration 0: log likelihood = -498130.58 (not concave)
    Iteration 1: log likelihood = -498038.76 (not concave)
    Iteration 2: log likelihood = -498018.82 (not concave)
    Iteration 3: log likelihood = -497874.11 (not concave)
    Iteration 4: log likelihood = -497813.55 (not concave)
    Iteration 5: log likelihood = -497712.61
    Iteration 6: log likelihood = -497653.86
    Iteration 7: log likelihood = -497641.55
    Iteration 8: log likelihood = -497633.73
    Iteration 9: log likelihood = -497623.72
    Iteration 10: log likelihood = -497618.9
    Iteration 11: log likelihood = -497614.62
    Iteration 12: log likelihood = -497613.67
    Iteration 13: log likelihood = -497613.37
    Iteration 14: log likelihood = -497613.37

    Mixed-effects logistic regression Number of obs = 6313872

    -------------------------------------------------------------
    | No. of Observations per Group
    Group Variable | Groups Minimum Average Maximum
    ----------------+--------------------------------------------
    codigodivi~o | 36 1,953 175,385.3 1862553
    id | 1,120 1 5,637.4 1862553
    -------------------------------------------------------------

    Integration method: mvaghermite Integration pts. = 7

    Wald chi2(7) = 253629.68
    Log likelihood = -497613.37 Prob > chi2 = 0.0000
    ------------------------------------------------------------------------------
    mortalidad | Coef. Legend
    -------------+----------------------------------------------------------------
    edad | .0887654 _b[edad]
    genero1 | .6754843 _b[genero1]

    _cons | -9.571593 _b[_cons]
    -------------+----------------------------------------------------------------
    codigodivi~o |
    var(_cons)| .039265 _b[/var(_cons[codigodivipoladepartamento])]
    -------------+----------------------------------------------------------------
    codigodivi~o>|
    id |
    var(_cons)| .1093776 _b[/var(_cons[codigodivipoladepartamento>id])]
    ------------------------------------------------------------------------------
    LR test vs. logistic model: chi2(2) = 8963.58 Prob > chi2 = 0.0000

    Note: LR test is conservative and provided only for reference.

    .


    . nlcom exp(sqrt(2*_b[edad])*invnormal(0.75)), cformat(%9.2f)

    _nl_1: exp(sqrt(2*_b[edad])*invnormal(0.75))

    ------------------------------------------------------------------------------
    mortalidad | Coef. Std. Err. z P>|z| [95% Conf. Interval]
    -------------+----------------------------------------------------------------
    _nl_1 | 1.33 0.00 3499.28 0.000 1.33 1.33
    ------------------------------------------------------------------------------

    . nlcom exp(sqrt(2*_b[genero1])*invnormal(0.75)), cformat(%9.2f)

    _nl_1: exp(sqrt(2*_b[genero1])*invnormal(0.75))

    ------------------------------------------------------------------------------
    mortalidad | Coef. Std. Err. z P>|z| [95% Conf. Interval]
    -------------+----------------------------------------------------------------
    _nl_1 | 2.19 0.01 294.11 0.000 2.18 2.20
    ------------------------------------------------------------------------------


  • #2
    Duplicate post. If interested, see https://www.statalist.org/forums/for...atio-calculate

    Comment

    Working...
    X