João Camargos 21/02/2022
#Packages
if (!require("pacman")) install.packages("pacman")## Carregando pacotes exigidos: pacman
pacman::p_load(tidyverse, haven, survey, sjPlot, ggeffects, DescTools, psych, rcompanion)
options(scipen = 999)#Dowloading and adapting the data set
setwd("C:/Users/Dell/OneDrive/Documentos/JOAO/Artigos/Narrativa Bolsonaro")
bd <- read_sav("Dados_ALMG_2021_06_29.sav")
dados <- bd %>%
dplyr::select( c("ID","P41", "P47","P5", "p5x", "p6x", "p2x","P3", "p3x", "p4x", "p9a1","p35b"))
#Adapting the bank
#Emotions
dados <- dados %>%
mutate(emocoes = case_when(P41 == 1 ~ "Desânimo",P41 == 2 ~ "Entusiamos", P41 ==3 ~ "Medo",P41 == 4 ~ "Esperança", P41 ==5 ~ "Preocupação",P41 == 6 ~ "Confiança", P41 ==9 ~ NA_character_),
emocoes_ag = case_when(P41 == 1 |P41 == 3|P41 == 5 ~ "Emoções Ansiedade", P41 == 2 |P41 == 4|P41 == 6 ~ "Emoções Entusiasmo"),
agregado = case_when(P41 == 1 |P41 == 3|P41 == 5 ~ 1, P41 == 2 |P41 == 4|P41 == 6 ~ 2))
#Belief that Bolsonaro was send by God
dados <- dados %>%
mutate(deus_bolso = case_when(P47 == 1 ~ "Sim, concorda",P47 == 2 ~ "Não concorda", P47 == 9 ~ NA_character_))
#Sex
dados <- dados %>%
mutate(sexo = case_when(p2x == 1 ~ "Feminino", p2x == 2 ~ "Masculino"))
#Age
dados <- dados%>%
rename(Idade = P3)
dados <- dados %>%
mutate(idadeAg = case_when(Idade %in% 1:24 ~ "Até 24 anos",
Idade %in% 25:34 ~ "25 anos a 34 anos",
Idade %in% 35:44 ~ "35 anos a 44 anos",
Idade %in% 45:54 ~ "45 anos a 54 anos",
Idade %in% 55:64 ~ "55 anos a 64 anos",
Idade >= 65 ~ "65 anos ou mais"))
#Scholarity
dados <- dados %>%
mutate(escolaridade = case_when(p4x == 1 ~ "Fundamental I com/inc", p4x == 2 ~ "Fundamental II com/inc", p4x == 3 ~ "Ensino Médio com/inc", p4x == 4 ~ "Superior com/inc", p4x == 5 ~ "Pós-graduação"))
#Religion
dados <- dados %>%
mutate(religiao = case_when(P5 == 1 ~ "Católica",P5 == 2 ~ "Protestante Historico",
P5 == 3 ~ "Pentecostal",P5 == 4 ~ "Espirita",
P5 %in% 5:11 ~ "outras", P5 == 98 ~ "Não tem" ))
#Religião Evangélica
dados <- dados %>%
mutate(religiaoe = ifelse(p5x == 2, "Evangélicas", "Outro"))
#Religião Pentecostal
dados <- dados %>%
mutate(religiaop = ifelse(P5 == 3, "Pentecostal", "Outro"))
#Renda
dados <- dados %>%
mutate(renda = case_when(p6x == 2 ~ "Até 2 SM", p6x == 3 ~ "De 2 a 5 SM", p6x == 4 ~ "Mais de 5 SM"))
#Apoio Bolsonaro
dados <- dados %>% mutate(apoio_b = case_when(p9a1 == 2 ~ "Aprova", p9a1 == 4 ~ "Regular", p9a1 == 6 ~ "Desaprova", p9a1 == 9 ~ NA_character_))
#Apoio Bolsonaro Ag
dados <- dados %>% mutate(apoio_ag = case_when(p9a1 == 2 ~ "Apoia",p9a1 == 9~ NA_character_ , p9a1 != 2 & p9a1 != 9 ~ "Outro"))
#Padronizando os dados
dados <- mutate_all(dados, as.factor)
dados$Idade <- as.numeric(dados$Idade)
dados$deus_bolso <- relevel(dados$deus_bolso, ref = "Não concorda")
dados$sexo <- relevel(dados$sexo, ref = "Feminino")
dados$religiaoe <- relevel(dados$religiaoe, ref = "Outro")
dados$religiaop <- relevel(dados$religiaop, ref = "Outro")
dados$emocoes_ag <- relevel(dados$emocoes_ag, ref = "Emoções Ansiedade")
dados$apoio_ag <- relevel(dados$apoio_ag, ref = "Outro")Frequencies without models
janitor::tabyl(dados$deus_bolso)## dados$deus_bolso n percent valid_percent
## Não concorda 1641 0.82214429 0.8784797
## Sim, concorda 227 0.11372745 0.1215203
## <NA> 128 0.06412826 NA
Creating a survey object
survey <- survey::svydesign(id = ~ID, data = dados)## Warning in svydesign.default(id = ~ID, data = dados): No weights or
## probabilities supplied, assuming equal probability
survey <- survey::as.svrepdesign(survey)#Post-stratifying the data set with rike and 2010 census data
sexo <- c(rep("Masculino", 9641877), rep("Feminino",9955453))
sexo <- as.data.frame(table(sexo))
idadeAg <- c(rep("Até 24 anos",3452004), rep("25 anos a 34 anos",3300848),
rep("35 anos a 44 anos",2789680), rep("45 anos a 54 anos",2424956),
rep("55 anos a 64 anos",1639595), rep("65 anos ou mais",1596289))
idadeAg <- as.data.frame(table(idadeAg))
religiao <- c(rep("Católica",13841945), rep("Protestante Historico",1699815),
rep("Pentecostal",2257704), rep("Espirita",419094),
rep("outras",213710),rep("Não tem", 986626))
religiao <- as.data.frame(table(religiao))
psurvey <- rake(survey, list(~idadeAg, ~sexo, ~religiao), list(idadeAg,sexo, religiao))#Frequency of Belief, Emotional system, and Government Evaluation
survey::svymean(~deus_bolso, psurvey, na.rm = T)## mean SE
## deus_bolsoNão concorda 0.89985 0.0067
## deus_bolsoSim, concorda 0.10015 0.0067
confint(survey::svymean(~deus_bolso, psurvey, na.rm = T))## 2.5 % 97.5 %
## deus_bolsoNão concorda 0.88667602 0.9130284
## deus_bolsoSim, concorda 0.08697161 0.1133240
survey::svymean(~emocoes_ag, psurvey, na.rm = T)## mean SE
## emocoes_agEmoções Ansiedade 0.64959 0.0112
## emocoes_agEmoções Entusiasmo 0.35041 0.0112
confint(survey::svymean(~emocoes_ag, psurvey, na.rm = T))## 2.5 % 97.5 %
## emocoes_agEmoções Ansiedade 0.6276452 0.6715373
## emocoes_agEmoções Entusiasmo 0.3284627 0.3723548
survey::svymean(~apoio_b, psurvey, na.rm = T)## mean SE
## apoio_bAprova 0.25349 0.0100
## apoio_bDesaprova 0.52346 0.0118
## apoio_bRegular 0.22304 0.0102
confint(survey::svymean(~apoio_b, psurvey, na.rm = T))## 2.5 % 97.5 %
## apoio_bAprova 0.2338631 0.2731222
## apoio_bDesaprova 0.5002543 0.5466704
## apoio_bRegular 0.2030062 0.2430837
#Crosstable of belief that Bolsonaro was send by God by federal government evaluation (data colected and the graphics were ploted in Excel)
n <- as.table(svytotal(~apoio_b, psurvey, na.rm = T))
CT1t <- as.table(svytotal(~interaction(apoio_b,deus_bolso), psurvey, na.rm = T))
CT1c <- as.table(confint(svytotal(~interaction(apoio_b,deus_bolso), psurvey, na.rm = T)))
CT1 <- cbind(CT1t, CT1c)
rm(CT1t, CT1c)
#First CT1t = Do not believe, Second CT1 = Believe
approve <- (c(CT1[1,], CT1[4,])/n[1])*100
disapprove <- (c(CT1[2,], CT1[5,])/n[2])*100
regular <- (c(CT1[3,], CT1[6,])/n[3])*100
CT1f <- rbind(approve, disapprove, regular)
rm(approve, disapprove, regular,n)
CT1f## CT1t 2.5 % 97.5 % CT1t 2.5 % 97.5 %
## approve 60.84678 54.16676 67.52681 30.1320265 25.641395613 34.622657
## disapprove 96.29460 91.78835 100.80086 0.5373648 -0.006583574 1.081313
## regular 84.54534 76.01245 93.07823 6.5594436 4.301950767 8.816936
Dispersion measures
svychisq(~interaction(deus_bolso,emocoes_ag), psurvey)##
## Pearson's X^2: Rao & Scott adjustment
##
## data: svychisq(~interaction(deus_bolso, emocoes_ag), psurvey)
## F = 1666, ndf = 1, ddf = 1984, p-value < 0.00000000000000022
DescTools::ContCoef(dados$deus_bolso, dados$emocoes_ag, correct = T)## [1] 0.2749319
rcompanion::cramerV(dados$deus_bolso, dados$emocoes_ag)## Cramer V
## 0.1354
#Crosstable of religion by belief that Bolsonaro was send by God (data colected and the graphics were ploted in Excel)
n <-as.table(svytotal(~religiaop, psurvey, na.rm = T))
CT2t <- as.table(svytotal(~interaction(deus_bolso,religiaop), psurvey, na.rm = T))
CT2c <-as.table(confint(svytotal(~interaction(deus_bolso,religiaop), psurvey, na.rm = T)))
#First CT2t=neontecostal Second CT2t = other
CT2 <- cbind(CT2t, CT2c)
rm(CT2t,CT2c)
other <- (c(CT2[1,], CT2[3,])/n[1])*100
pentecost<-(c(CT2[2,], CT2[4,])/n[2])*100
CT2f <- rbind(pentecost, other)
CT2f## CT2t 2.5 % 97.5 % CT2t 2.5 % 97.5 %
## pentecost 58.72823 48.94396 68.51249 22.061822 17.73948 26.38417
## other 86.58574 84.88042 88.29106 8.915115 8.26013 9.57010
Association measures
svychisq(~interaction(religiao,deus_bolso), psurvey)##
## Pearson's X^2: Rao & Scott adjustment
##
## data: svychisq(~interaction(religiao, deus_bolso), psurvey)
## F = 1719.7, ndf = 4.7825, ddf = 9488.5302, p-value <
## 0.00000000000000022
DescTools::ContCoef(dados$deus_bolso, dados$emocoes_ag, correct = T)## [1] 0.2749319
rcompanion::cramerV(dados$deus_bolso, dados$emocoes_ag)## Cramer V
## 0.1354
#Crosstable of Emotional system by belief that Bolsonaro was send by God (data colected and the graphics were ploted in Excel)
n <- as.table(svytotal(~deus_bolso, psurvey, na.rm = T))
CT3t <- as.table(svytotal(~interaction(deus_bolso,emocoes_ag), psurvey, na.rm = T))
CT3c <-as.table(confint(svytotal(~interaction(deus_bolso,emocoes_ag), psurvey, na.rm = T)))
CT3 <- cbind(CT3t, CT3c)
rm(CT3t, CT3c)
#First CT1t =Surveillance System, Second CT1 = Disposition System
believe <- (c(CT3[1,], CT3[3,])/n[1])*100
nbelieve <- (c(CT3[2,], CT3[4,])/n[2])*100
CT3f <- rbind(believe, nbelieve)
CT3f## CT3t 2.5 % 97.5 % CT3t 2.5 % 97.5 %
## believe 68.54043 65.84877 71.23209 31.20261 28.76856 33.63666
## nbelieve 36.10616 28.00316 44.20916 63.34395 52.43080 74.25709
Association measures
svychisq(~interaction(deus_bolso,emocoes_ag), psurvey)##
## Pearson's X^2: Rao & Scott adjustment
##
## data: svychisq(~interaction(deus_bolso, emocoes_ag), psurvey)
## F = 1666, ndf = 1, ddf = 1984, p-value < 0.00000000000000022
DescTools::ContCoef(dados$deus_bolso, dados$emocoes_ag, correct = T)## [1] 0.2749319
psych::phi(table(dados$deus_bolso, dados$emocoes_ag))## [1] 0.2
rcompanion::cramerV(dados$deus_bolso, dados$emocoes_ag)## Cramer V
## 0.1354
#Structural equations model
terms1 <- c("deus_bolsoSim, concorda" = "Believe", "religiaopPentecostal" = "Pentecostal", "sexoMasculino" = "Male", "escolaridadeFundamental I com/inc" = "Primary I complete/incomplete", "escolaridadeFundamental II com/inc" = "Primary II complete/incomplete", "escolaridadeSuperior com/inc" = "Graduate", "rendaDe 2 a 5 SM" = "2 to 5 minimum salaries", "rendaMais de 5 SM" = "Over 5 minimum salaries")
terms2 <- c("deus_bolsoSim, concorda" = "Believe", "religiaopPentecostal" = "Pentecostal", "sexoMasculino" = "Male", "escolaridadeFundamental I com/inc" = "Primary I complete/incomplete", "escolaridadeFundamental II com/inc" = "Primary II complete/incomplete", "escolaridadeSuperior com/inc" = "Graduate", "rendaDe 2 a 5 SM" = "2 to 5 minimum salaries", "rendaMais de 5 SM" = "Over 5 minimum salaries","emoM" = "Dispositional System")
#1 Step
fit.totaleffefct2 <- glm(apoio_ag~deus_bolso+ religiaop + sexo + Idade + escolaridade + renda, data = dados, family = "binomial")
summary(fit.totaleffefct2)##
## Call:
## glm(formula = apoio_ag ~ deus_bolso + religiaop + sexo + Idade +
## escolaridade + renda, family = "binomial", data = dados)
##
## Deviance Residuals:
## Min 1Q Median 3Q Max
## -2.3040 -0.6896 -0.5534 0.4984 2.3236
##
## Coefficients:
## Estimate Std. Error z value
## (Intercept) -2.295536 0.168583 -13.617
## deus_bolsoSim, concorda 2.812390 0.192175 14.634
## religiaopPentecostal 0.577823 0.155360 3.719
## sexoMasculino 0.679311 0.123900 5.483
## Idade 0.017175 0.004442 3.867
## escolaridadeFundamental I com/inc -0.557736 0.179819 -3.102
## escolaridadeFundamental II com/inc -0.099666 0.177830 -0.560
## escolaridadeSuperior com/inc -0.015010 0.181055 -0.083
## rendaDe 2 a 5 SM 0.193773 0.135532 1.430
## rendaMais de 5 SM 0.342770 0.215189 1.593
## Pr(>|z|)
## (Intercept) < 0.0000000000000002 ***
## deus_bolsoSim, concorda < 0.0000000000000002 ***
## religiaopPentecostal 0.00020 ***
## sexoMasculino 0.0000000419 ***
## Idade 0.00011 ***
## escolaridadeFundamental I com/inc 0.00192 **
## escolaridadeFundamental II com/inc 0.57517
## escolaridadeSuperior com/inc 0.93393
## rendaDe 2 a 5 SM 0.15280
## rendaMais de 5 SM 0.11119
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## (Dispersion parameter for binomial family taken to be 1)
##
## Null deviance: 2140.3 on 1835 degrees of freedom
## Residual deviance: 1726.9 on 1826 degrees of freedom
## (160 observations deleted due to missingness)
## AIC: 1746.9
##
## Number of Fisher Scoring iterations: 4
exp(fit.totaleffefct2$coefficients)## (Intercept) deus_bolsoSim, concorda
## 0.1007074 16.6496597
## religiaopPentecostal sexoMasculino
## 1.7821537 1.9725182
## Idade escolaridadeFundamental I com/inc
## 1.0173233 0.5725035
## escolaridadeFundamental II com/inc escolaridadeSuperior com/inc
## 0.9051400 0.9851017
## rendaDe 2 a 5 SM rendaMais de 5 SM
## 1.2138208 1.4088440
#2 Step
fit.mediator2=glm(emocoes_ag~deus_bolso+ religiaop + sexo + Idade + escolaridade + renda, data = dados, family = "binomial")
summary(fit.mediator2)##
## Call:
## glm(formula = emocoes_ag ~ deus_bolso + religiaop + sexo + Idade +
## escolaridade + renda, family = "binomial", data = dados)
##
## Deviance Residuals:
## Min 1Q Median 3Q Max
## -1.6815 -0.9188 -0.7803 1.3064 1.8667
##
## Coefficients:
## Estimate Std. Error z value
## (Intercept) -1.200672 0.131899 -9.103
## deus_bolsoSim, concorda 1.147218 0.153630 7.467
## religiaopPentecostal -0.013029 0.134475 -0.097
## sexoMasculino 0.378745 0.100612 3.764
## Idade 0.008802 0.003666 2.401
## escolaridadeFundamental I com/inc 0.063609 0.144048 0.442
## escolaridadeFundamental II com/inc 0.241673 0.145770 1.658
## escolaridadeSuperior com/inc -0.185082 0.156054 -1.186
## rendaDe 2 a 5 SM 0.149796 0.111704 1.341
## rendaMais de 5 SM -0.238922 0.195112 -1.225
## Pr(>|z|)
## (Intercept) < 0.0000000000000002 ***
## deus_bolsoSim, concorda 0.0000000000000818 ***
## religiaopPentecostal 0.922812
## sexoMasculino 0.000167 ***
## Idade 0.016357 *
## escolaridadeFundamental I com/inc 0.658795
## escolaridadeFundamental II com/inc 0.097338 .
## escolaridadeSuperior com/inc 0.235616
## rendaDe 2 a 5 SM 0.179918
## rendaMais de 5 SM 0.220749
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## (Dispersion parameter for binomial family taken to be 1)
##
## Null deviance: 2437.1 on 1858 degrees of freedom
## Residual deviance: 2326.6 on 1849 degrees of freedom
## (137 observations deleted due to missingness)
## AIC: 2346.6
##
## Number of Fisher Scoring iterations: 4
exp(fit.mediator2$coefficients)## (Intercept) deus_bolsoSim, concorda
## 0.3009920 3.1494205
## religiaopPentecostal sexoMasculino
## 0.9870550 1.4604506
## Idade escolaridadeFundamental I com/inc
## 1.0088412 1.0656751
## escolaridadeFundamental II com/inc escolaridadeSuperior com/inc
## 1.2733772 0.8310360
## rendaDe 2 a 5 SM rendaMais de 5 SM
## 1.1615968 0.7874765
sjPlot::plot_model(fit.mediator2, axis.labels = terms1, title = "First equation - Effects on emotions")stargazer::stargazer(fit.mediator2, type = "text", out = "FE.doc", dep.var.labels = "Emotional System",dep.var.caption = "", covariate.labels = c("Believe", "Pentecostal", "Male", "Age", "Primary I complete/incomplete", "Primary II complete/incomplete", "Graduate","2 to 5 minimum salaries","Over 5 minimum salaries"), title = "First equation - Effects on emotions")##
## First equation - Effects on emotions
## ==========================================================
## Emotional System
## ----------------------------------------------------------
## Believe 1.147***
## (0.154)
##
## Pentecostal -0.013
## (0.134)
##
## Male 0.379***
## (0.101)
##
## Age 0.009**
## (0.004)
##
## Primary I complete/incomplete 0.064
## (0.144)
##
## Primary II complete/incomplete 0.242*
## (0.146)
##
## Graduate -0.185
## (0.156)
##
## 2 to 5 minimum salaries 0.150
## (0.112)
##
## Over 5 minimum salaries -0.239
## (0.195)
##
## Constant -1.201***
## (0.132)
##
## ----------------------------------------------------------
## Observations 1,859
## Log Likelihood -1,163.305
## Akaike Inf. Crit. 2,346.610
## ==========================================================
## Note: *p<0.1; **p<0.05; ***p<0.01
#Yule transformation
(exp(fit.mediator2$coefficients)-1)/(exp(fit.mediator2$coefficients)+1)## (Intercept) deus_bolsoSim, concorda
## -0.537288503 0.518004985
## religiaopPentecostal sexoMasculino
## -0.006514642 0.187140776
## Idade escolaridadeFundamental I com/inc
## 0.004401158 0.031793537
## escolaridadeFundamental II com/inc escolaridadeSuperior com/inc
## 0.120251575 -0.092277816
## rendaDe 2 a 5 SM rendaMais de 5 SM
## 0.074758071 -0.118895851
#3 Step
fit.dv2=glm(apoio_ag~deus_bolso+emocoes_ag+ religiaop + sexo + Idade + escolaridade + renda, data = dados, family = "binomial")
summary(fit.dv2)##
## Call:
## glm(formula = apoio_ag ~ deus_bolso + emocoes_ag + religiaop +
## sexo + Idade + escolaridade + renda, family = "binomial",
## data = dados)
##
## Deviance Residuals:
## Min 1Q Median 3Q Max
## -2.3492 -0.6532 -0.4974 0.4235 2.4135
##
## Coefficients:
## Estimate Std. Error z value
## (Intercept) -2.632700 0.180136 -14.615
## deus_bolsoSim, concorda 2.664922 0.196845 13.538
## emocoes_agEmoções Entusiasmo 1.046843 0.125329 8.353
## religiaopPentecostal 0.597019 0.159351 3.747
## sexoMasculino 0.625523 0.126770 4.934
## Idade 0.014953 0.004551 3.286
## escolaridadeFundamental I com/inc -0.552957 0.182347 -3.032
## escolaridadeFundamental II com/inc -0.142835 0.181427 -0.787
## escolaridadeSuperior com/inc 0.034304 0.186783 0.184
## rendaDe 2 a 5 SM 0.168073 0.139164 1.208
## rendaMais de 5 SM 0.432348 0.221830 1.949
## Pr(>|z|)
## (Intercept) < 0.0000000000000002 ***
## deus_bolsoSim, concorda < 0.0000000000000002 ***
## emocoes_agEmoções Entusiasmo < 0.0000000000000002 ***
## religiaopPentecostal 0.000179 ***
## sexoMasculino 0.000000804 ***
## Idade 0.001017 **
## escolaridadeFundamental I com/inc 0.002426 **
## escolaridadeFundamental II com/inc 0.431115
## escolaridadeSuperior com/inc 0.854280
## rendaDe 2 a 5 SM 0.227149
## rendaMais de 5 SM 0.051295 .
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## (Dispersion parameter for binomial family taken to be 1)
##
## Null deviance: 2133.8 on 1831 degrees of freedom
## Residual deviance: 1651.6 on 1821 degrees of freedom
## (164 observations deleted due to missingness)
## AIC: 1673.6
##
## Number of Fisher Scoring iterations: 4
exp(fit.dv2$coefficients)## (Intercept) deus_bolsoSim, concorda
## 0.07188408 14.36683152
## emocoes_agEmoções Entusiasmo religiaopPentecostal
## 2.84864319 1.81669437
## sexoMasculino Idade
## 1.86922305 1.01506520
## escolaridadeFundamental I com/inc escolaridadeFundamental II com/inc
## 0.57524638 0.86689739
## escolaridadeSuperior com/inc rendaDe 2 a 5 SM
## 1.03489962 1.18302338
## rendaMais de 5 SM
## 1.54087148
sjPlot::plot_model(fit.dv2, axis.labels = terms2, title = "Second equation - Total effects")stargazer::stargazer(fit.dv2, type = "text", out = "SE.doc", dep.var.labels = "Government approval", dep.var.caption = "",covariate.labels = c("Believe", "Disposition System", "Pentecostal", "Male", "Age", "Primary I complete/incomplete", "Primary II complete/incomplete", "Graduate","2 to 5 minimum salaries","Over 5 minimum salaries"), title = "Second equation - Total effects on Government Approval")##
## Second equation - Total effects on Government Approval
## ==========================================================
## Government approval
## ----------------------------------------------------------
## Believe 2.665***
## (0.197)
##
## Disposition System 1.047***
## (0.125)
##
## Pentecostal 0.597***
## (0.159)
##
## Male 0.626***
## (0.127)
##
## Age 0.015***
## (0.005)
##
## Primary I complete/incomplete -0.553***
## (0.182)
##
## Primary II complete/incomplete -0.143
## (0.181)
##
## Graduate 0.034
## (0.187)
##
## 2 to 5 minimum salaries 0.168
## (0.139)
##
## Over 5 minimum salaries 0.432*
## (0.222)
##
## Constant -2.633***
## (0.180)
##
## ----------------------------------------------------------
## Observations 1,832
## Log Likelihood -825.784
## Akaike Inf. Crit. 1,673.568
## ==========================================================
## Note: *p<0.1; **p<0.05; ***p<0.01
#Yule transformation
(exp(fit.dv2$coefficients)-1)/(exp(fit.dv2$coefficients)+1)## (Intercept) deus_bolsoSim, concorda
## -0.865873404 0.869849552
## emocoes_agEmoções Entusiasmo religiaopPentecostal
## 0.480336342 0.289947811
## sexoMasculino Idade
## 0.302947187 0.007476283
## escolaridadeFundamental I com/inc escolaridadeFundamental II com/inc
## -0.269642660 -0.071296155
## escolaridadeSuperior com/inc rendaDe 2 a 5 SM
## 0.017150537 0.083839406
## rendaMais de 5 SM
## 0.212868492
Direct and indirect effects
IndEY <- 0.5254695942*0.480336342
IndE <-(IndEY+1)/(1-IndEY)
IndE## [1] 1.675235
ADEY <- 0.869849552
ADE <-(ADEY+1)/(1-ADEY)
ADE## [1] 14.36683
TF <- ADE + IndE
TF## [1] 16.04207
Prop <- IndE/TF
Prop## [1] 0.1044276