-----Original Message-----
From: rosita21 at gmail.com
Sent: Thu, 14 Apr 2016 19:07:04 +0100
To: pd.mes at cbs.dk, r-help at r-project.org
Subject: [R] Odds Ratio and OR CI
Howdy everyone
I?m trying to get Odds ratio and OR confidence intervals using a probit
model, but I'm not getting.
Do you think you can help me?
I?m new with R L
naive =
summary(glm(pcr.data[,7]~boldBeta_individual+pcr.data$age,family=binomial(link=probit)))
naive_answer = c(naive$coefficients[,1:3])
#naive estimates for
#alpha (first 4 collumns: intercept; beta_intercept, beta_slope and age)
and
#and SE(last 4 collumns: intercept; beta_intercept, beta_slope and age)
OR.naive = exp(1.6*coef(naive))
(till here works, the problem is with the confidence interval)
I tried to get the Standard error from the variance, but I?m not sure if
this can be done as I?ve done.
Var_coef <- 1.6^2*var(coef(naive))
SE_coef <- Var_coef/sqrt(nsample) ########## I thi k
this is correct
OR.naive.inf <- exp(OR.naive - (1.96 * SE_coef))
OR.naive.sup <- exp(OR.naive + (1.96 * SE_coef))
if I used logit link I would get the CI with confint(na?ve) command, but
with probit I don't think so. Is there a way?
What should I do?
Atenciosamente,
Rosa Oliveira
--