library(tidyverse)
## ── Attaching core tidyverse packages ──────────────────────── tidyverse 2.0.0 ──
## ✔ dplyr     1.1.2     ✔ readr     2.1.4
## ✔ forcats   1.0.0     ✔ stringr   1.5.0
## ✔ ggplot2   3.4.2     ✔ tibble    3.2.1
## ✔ lubridate 1.9.2     ✔ tidyr     1.3.0
## ✔ purrr     1.0.1     
## ── Conflicts ────────────────────────────────────────── tidyverse_conflicts() ──
## ✖ dplyr::filter() masks stats::filter()
## ✖ dplyr::lag()    masks stats::lag()
## ℹ Use the conflicted package (<http://conflicted.r-lib.org/>) to force all conflicts to become errors
library(dplyr)  
library(conflicted)
library(erer)
## Loading required package: lmtest
## Loading required package: zoo
## 
## Attaching package: 'zoo'
## 
## The following objects are masked from 'package:base':
## 
##     as.Date, as.Date.numeric
## 
## Registered S3 method overwritten by 'quantmod':
##   method            from
##   as.zoo.data.frame zoo
library(foreign)
library(nnet)
library(stargazer)
## 
## Please cite as: 
## 
##  Hlavac, Marek (2022). stargazer: Well-Formatted Regression and Summary Statistics Tables.
##  R package version 5.2.3. https://CRAN.R-project.org/package=stargazer
trang = read.csv("D:\\OneDrive - UMP\\R - lenh 2016\\2752023trangytcc.csv", header=T)

trang.1 = trang %>% mutate (gioi=recode(gioi,"1"="nam","2"="nu"),
     tuoi_n = recode(tuoi_n, "1"="1.<30 tuoi", "2"="2.40-49 tuoi", "3"= "3.>50 tuoi"),
      hocvan = recode(hocvan,"1"="1.Trung-cap","2"="2.CD-DH","3"="3.SDH"),
      honnhan= recode(honnhan,"1"="chua ket hon","2"="Da ket hon","3"="Ly hon"),
     dantoc = recode(dantoc,"1"="kinh","2"="khac"),
      tongiao = recode(tongiao,"1"="khong dao","2"="phat giao", "3"="thien chua"),
      noio = recode(noio,"1"="tro","2"="gia dinh", "3"="nguoi quen", "4"="khac"),
   socon = recode(socon, "0"="0.con","1"="1.con","2"="2.con","3"="3.con"),
   kinhte = recode(kinhte,"1"="1.giau","2"="2.kha","3"="3.vua du","4"="4.kho khan"),
   ban = recode(ban,"1"="phong","2"="lam sang","3"="can lam sang"),
   thamnien=recode(thamnien,"1"="<1 nam","2"=">1-5nam","3"=">5-10nam","4"=">10-15nam","5"=">15-20 nam","6"=">20 nam"),
   nhiemvu = recode(nhiemvu,"1"="dieu tri","2"="cham soc","3"="can lam sang","4"="chuyenvien"),
   mucdogjs_2 = recode(mucdogjs_2,"0"="0.kohailong","1"="1.hailong"),
  mucdoUWES_2 = recode(mucdoUWES_2,"0"="0.ko_ganket","1"="1.gan ket"),
outuwes_3 = recode(outuwes_3,"0"="0.gan ket","1"="1.TB gan ket", "2"="2. Gan ket cao"),
outgjs_3 = recode(outgjs_3,"0"="0.hai long","1"="1.hai long TB", "2"="2.hai long cao"))

names(trang.1)
##  [1] "id"          "gioi"        "tuoi"        "tuoi_n"      "dantoc"     
##  [6] "noisong"     "noio"        "tongiao"     "hocvan"      "honnhan"    
## [11] "socon"       "kinhte"      "thamnien"    "ban"         "nhiemvu"    
## [16] "UWES91"      "UWES92"      "UWES93"      "UWES94"      "UWES95"     
## [21] "UWES96"      "UWES97"      "UWES98"      "UWES99"      "sucsong"    
## [26] "conghien"    "sayme"       "uwesTong"    "mucdoUWES_2" "outuwes_3"  
## [31] "GJS1"        "GJS2"        "GJS3"        "GJS4"        "GJS5"       
## [36] "GJS6"        "GJS7"        "GJS8"        "GJS9"        "GJS10"      
## [41] "gjsTong"     "mucdogjs_2"  "mucdo_gjs"   "outgjs_3"
attach(trang.1)

library(table1)
table1(~factor(gioi) + tuoi + factor(tuoi_n) + factor(dantoc) + factor(noio)
       + factor(tongiao) + factor(hocvan) + factor(honnhan)
       + factor(socon) + factor(kinhte) + factor(thamnien)
       + factor(ban) + factor(nhiemvu), data = trang.1)
Overall
(N=355)
factor(gioi)
nam 124 (34.9%)
nu 231 (65.1%)
tuoi
Mean (SD) 32.1 (6.76)
Median [Min, Max] 30.0 [22.0, 55.0]
factor(tuoi_n)
1.<30 tuoi 158 (44.5%)
2.40-49 tuoi 144 (40.6%)
3.>50 tuoi 53 (14.9%)
factor(dantoc)
khac 13 (3.7%)
kinh 342 (96.3%)
factor(noio)
gia dinh 202 (56.9%)
nguoi quen 15 (4.2%)
tro 138 (38.9%)
factor(tongiao)
khong dao 274 (77.2%)
phat giao 58 (16.3%)
thien chua 23 (6.5%)
factor(hocvan)
1.Trung-cap 39 (11.0%)
2.CD-DH 277 (78.0%)
3.SDH 39 (11.0%)
factor(honnhan)
chua ket hon 152 (42.8%)
Da ket hon 196 (55.2%)
Ly hon 7 (2.0%)
factor(socon)
0.con 198 (55.8%)
1.con 82 (23.1%)
2.con 68 (19.2%)
3.con 7 (2.0%)
factor(kinhte)
1.giau 14 (3.9%)
2.kha 22 (6.2%)
3.vua du 245 (69.0%)
4.kho khan 74 (20.8%)
factor(thamnien)
<1 nam 29 (8.2%)
>1-5nam 163 (45.9%)
>10-15nam 35 (9.9%)
>15-20 nam 9 (2.5%)
>20 nam 6 (1.7%)
>5-10nam 113 (31.8%)
factor(ban)
can lam sang 67 (18.9%)
lam sang 224 (63.1%)
phong 64 (18.0%)
factor(nhiemvu)
can lam sang 60 (16.9%)
cham soc 142 (40.0%)
chuyenvien 66 (18.6%)
dieu tri 87 (24.5%)
table1(~factor(gioi) + tuoi + factor(tuoi_n) + factor(dantoc) + factor(noio)
       + factor(tongiao) + factor(hocvan) + factor(honnhan)
       + factor(socon) + factor(kinhte) + factor(thamnien)
       + factor(ban) + factor(nhiemvu) | factor(mucdoUWES_2) , data = trang.1)
0.ko_ganket
(N=83)
1.gan ket
(N=272)
Overall
(N=355)
factor(gioi)
nam 27 (32.5%) 97 (35.7%) 124 (34.9%)
nu 56 (67.5%) 175 (64.3%) 231 (65.1%)
tuoi
Mean (SD) 29.9 (5.52) 32.7 (6.96) 32.1 (6.76)
Median [Min, Max] 29.0 [22.0, 55.0] 31.0 [22.0, 54.0] 30.0 [22.0, 55.0]
factor(tuoi_n)
1.<30 tuoi 48 (57.8%) 110 (40.4%) 158 (44.5%)
2.40-49 tuoi 31 (37.3%) 113 (41.5%) 144 (40.6%)
3.>50 tuoi 4 (4.8%) 49 (18.0%) 53 (14.9%)
factor(dantoc)
khac 4 (4.8%) 9 (3.3%) 13 (3.7%)
kinh 79 (95.2%) 263 (96.7%) 342 (96.3%)
factor(noio)
gia dinh 42 (50.6%) 160 (58.8%) 202 (56.9%)
nguoi quen 3 (3.6%) 12 (4.4%) 15 (4.2%)
tro 38 (45.8%) 100 (36.8%) 138 (38.9%)
factor(tongiao)
khong dao 70 (84.3%) 204 (75.0%) 274 (77.2%)
phat giao 11 (13.3%) 47 (17.3%) 58 (16.3%)
thien chua 2 (2.4%) 21 (7.7%) 23 (6.5%)
factor(hocvan)
1.Trung-cap 11 (13.3%) 28 (10.3%) 39 (11.0%)
2.CD-DH 68 (81.9%) 209 (76.8%) 277 (78.0%)
3.SDH 4 (4.8%) 35 (12.9%) 39 (11.0%)
factor(honnhan)
chua ket hon 44 (53.0%) 108 (39.7%) 152 (42.8%)
Da ket hon 39 (47.0%) 157 (57.7%) 196 (55.2%)
Ly hon 0 (0%) 7 (2.6%) 7 (2.0%)
factor(socon)
0.con 56 (67.5%) 142 (52.2%) 198 (55.8%)
1.con 15 (18.1%) 67 (24.6%) 82 (23.1%)
2.con 11 (13.3%) 57 (21.0%) 68 (19.2%)
3.con 1 (1.2%) 6 (2.2%) 7 (2.0%)
factor(kinhte)
1.giau 4 (4.8%) 10 (3.7%) 14 (3.9%)
2.kha 2 (2.4%) 20 (7.4%) 22 (6.2%)
3.vua du 54 (65.1%) 191 (70.2%) 245 (69.0%)
4.kho khan 23 (27.7%) 51 (18.8%) 74 (20.8%)
factor(thamnien)
<1 nam 12 (14.5%) 17 (6.3%) 29 (8.2%)
>1-5nam 46 (55.4%) 117 (43.0%) 163 (45.9%)
>10-15nam 6 (7.2%) 29 (10.7%) 35 (9.9%)
>15-20 nam 2 (2.4%) 7 (2.6%) 9 (2.5%)
>20 nam 1 (1.2%) 5 (1.8%) 6 (1.7%)
>5-10nam 16 (19.3%) 97 (35.7%) 113 (31.8%)
factor(ban)
can lam sang 15 (18.1%) 52 (19.1%) 67 (18.9%)
lam sang 54 (65.1%) 170 (62.5%) 224 (63.1%)
phong 14 (16.9%) 50 (18.4%) 64 (18.0%)
factor(nhiemvu)
can lam sang 13 (15.7%) 47 (17.3%) 60 (16.9%)
cham soc 33 (39.8%) 109 (40.1%) 142 (40.0%)
chuyenvien 14 (16.9%) 52 (19.1%) 66 (18.6%)
dieu tri 23 (27.7%) 64 (23.5%) 87 (24.5%)
table1(~ factor(gioi) + tuoi + factor(tuoi_n)+ factor(dantoc) + factor(noio)
       + factor(tongiao) + factor(hocvan) + factor(honnhan)
       + factor(socon) + factor(kinhte) + factor(thamnien)
       + factor(ban) + factor(nhiemvu) | factor(mucdogjs_2), data = trang.1)
0.kohailong
(N=48)
1.hailong
(N=307)
Overall
(N=355)
factor(gioi)
nam 15 (31.3%) 109 (35.5%) 124 (34.9%)
nu 33 (68.8%) 198 (64.5%) 231 (65.1%)
tuoi
Mean (SD) 29.6 (5.35) 32.5 (6.88) 32.1 (6.76)
Median [Min, Max] 28.0 [22.0, 50.0] 31.0 [22.0, 55.0] 30.0 [22.0, 55.0]
factor(tuoi_n)
1.<30 tuoi 32 (66.7%) 126 (41.0%) 158 (44.5%)
2.40-49 tuoi 13 (27.1%) 131 (42.7%) 144 (40.6%)
3.>50 tuoi 3 (6.3%) 50 (16.3%) 53 (14.9%)
factor(dantoc)
khac 1 (2.1%) 12 (3.9%) 13 (3.7%)
kinh 47 (97.9%) 295 (96.1%) 342 (96.3%)
factor(noio)
gia dinh 20 (41.7%) 182 (59.3%) 202 (56.9%)
nguoi quen 2 (4.2%) 13 (4.2%) 15 (4.2%)
tro 26 (54.2%) 112 (36.5%) 138 (38.9%)
factor(tongiao)
khong dao 42 (87.5%) 232 (75.6%) 274 (77.2%)
phat giao 4 (8.3%) 54 (17.6%) 58 (16.3%)
thien chua 2 (4.2%) 21 (6.8%) 23 (6.5%)
factor(hocvan)
1.Trung-cap 5 (10.4%) 34 (11.1%) 39 (11.0%)
2.CD-DH 38 (79.2%) 239 (77.9%) 277 (78.0%)
3.SDH 5 (10.4%) 34 (11.1%) 39 (11.0%)
factor(honnhan)
chua ket hon 29 (60.4%) 123 (40.1%) 152 (42.8%)
Da ket hon 19 (39.6%) 177 (57.7%) 196 (55.2%)
Ly hon 0 (0%) 7 (2.3%) 7 (2.0%)
factor(socon)
0.con 38 (79.2%) 160 (52.1%) 198 (55.8%)
1.con 5 (10.4%) 77 (25.1%) 82 (23.1%)
2.con 5 (10.4%) 63 (20.5%) 68 (19.2%)
3.con 0 (0%) 7 (2.3%) 7 (2.0%)
factor(kinhte)
1.giau 3 (6.3%) 11 (3.6%) 14 (3.9%)
2.kha 1 (2.1%) 21 (6.8%) 22 (6.2%)
3.vua du 30 (62.5%) 215 (70.0%) 245 (69.0%)
4.kho khan 14 (29.2%) 60 (19.5%) 74 (20.8%)
factor(thamnien)
<1 nam 4 (8.3%) 25 (8.1%) 29 (8.2%)
>1-5nam 33 (68.8%) 130 (42.3%) 163 (45.9%)
>10-15nam 1 (2.1%) 34 (11.1%) 35 (9.9%)
>15-20 nam 1 (2.1%) 8 (2.6%) 9 (2.5%)
>20 nam 0 (0%) 6 (2.0%) 6 (1.7%)
>5-10nam 9 (18.8%) 104 (33.9%) 113 (31.8%)
factor(ban)
can lam sang 11 (22.9%) 56 (18.2%) 67 (18.9%)
lam sang 31 (64.6%) 193 (62.9%) 224 (63.1%)
phong 6 (12.5%) 58 (18.9%) 64 (18.0%)
factor(nhiemvu)
can lam sang 10 (20.8%) 50 (16.3%) 60 (16.9%)
cham soc 16 (33.3%) 126 (41.0%) 142 (40.0%)
chuyenvien 5 (10.4%) 61 (19.9%) 66 (18.6%)
dieu tri 17 (35.4%) 70 (22.8%) 87 (24.5%)
library(compareGroups)

dat.1 = data.frame(gioi, tuoi, tuoi_n, dantoc, noisong, noio, 
                   tongiao, hocvan, honnhan, socon, kinhte, as.factor(thamnien), 
                   ban, nhiemvu, mucdoUWES_2, mucdogjs_2, outuwes_3, outgjs_3)

kq_ganket = descrTable(mucdoUWES_2 ~., data = dat.1,
                       byrow = T, riskratio = T, 
                       show.ratio = T, digits.ratio = 2, show.all = T,
                       show.p.trend = T, method = 1,compute.ratio = T,
                       chisq.test.seed = T, p.corrected = T, ref=1)
## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect
kq_ganket
## 
## --------Summary descriptives table by 'mucdoUWES_2'---------
## 
## ___________________________________________________________________________________________________ 
##                         [ALL]    0.ko_ganket  1.gan ket         RR        p.ratio p.overall p.trend 
##                         N=355       N=83        N=272                                               
## ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯ 
## gioi:                                                                               0.695    0.695  
##     nam              124 (34.9%) 27 (21.8%)  97 (78.2%)        Ref.        Ref.                     
##     nu               231 (65.1%) 56 (24.2%)  175 (75.8%) 0.97 [0.86;1.09]  0.607                    
## tuoi                 32.1 (6.76) 29.9 (5.52) 32.7 (6.96)     . [.;.]         .     <0.001   <0.001  
## tuoi_n:                                                                             0.002    0.002  
##     1.<30 tuoi       158 (44.5%) 48 (30.4%)  110 (69.6%)       Ref.        Ref.                     
##     2.40-49 tuoi     144 (40.6%) 31 (21.5%)  113 (78.5%) 1.13 [0.99;1.29]  0.082                    
##     3.>50 tuoi       53 (14.9%)   4 (7.55%)  49 (92.5%)  1.33 [1.17;1.51] <0.001                    
## dantoc:                                                                             0.511    0.511  
##     khac             13 (3.66%)   4 (30.8%)   9 (69.2%)        Ref.        Ref.                     
##     kinh             342 (96.3%) 79 (23.1%)  263 (76.9%) 1.11 [0.77;1.60]  0.524                    
## noisong              1.09 (0.29) 1.12 (0.33) 1.08 (0.27) 0.89 [0.70;1.13]  0.335    0.319    0.319  
## noio:                                                                               0.366    0.366  
##     gia dinh         202 (56.9%) 42 (20.8%)  160 (79.2%)       Ref.        Ref.                     
##     nguoi quen       15 (4.23%)   3 (20.0%)  12 (80.0%)  1.01 [0.78;1.31]  0.984                    
##     tro              138 (38.9%) 38 (27.5%)  100 (72.5%) 0.91 [0.81;1.04]  0.154                    
## tongiao:                                                                            0.128    0.128  
##     khong dao        274 (77.2%) 70 (25.5%)  204 (74.5%)       Ref.        Ref.                     
##     phat giao        58 (16.3%)  11 (19.0%)  47 (81.0%)  1.09 [0.94;1.26]  0.295                    
##     thien chua       23 (6.48%)   2 (8.70%)  21 (91.3%)  1.23 [1.06;1.42]  0.063                    
## hocvan:                                                                             0.107    0.107  
##     1.Trung-cap      39 (11.0%)  11 (28.2%)  28 (71.8%)        Ref.        Ref.                     
##     2.CD-DH          277 (78.0%) 68 (24.5%)  209 (75.5%) 1.05 [0.85;1.29]  0.616                    
##     3.SDH            39 (11.0%)   4 (10.3%)  35 (89.7%)  1.25 [1.00;1.56]  0.051                    
## honnhan:                                                                            0.049    0.049  
##     chua ket hon     152 (42.8%) 44 (28.9%)  108 (71.1%)       Ref.        Ref.                     
##     Da ket hon       196 (55.2%) 39 (19.9%)  157 (80.1%) 1.13 [1.00;1.28]  0.052                    
##     Ly hon            7 (1.97%)   0 (0.00%)   7 (100%)   1.41 [1.27;1.56]  0.098                    
## socon:                                                                              0.107    0.107  
##     0.con            198 (55.8%) 56 (28.3%)  142 (71.7%)       Ref.        Ref.                     
##     1.con            82 (23.1%)  15 (18.3%)  67 (81.7%)  1.14 [1.00;1.30]  0.080                    
##     2.con            68 (19.2%)  11 (16.2%)  57 (83.8%)  1.17 [1.02;1.34]  0.045                    
##     3.con             7 (1.97%)   1 (14.3%)   6 (85.7%)  1.20 [0.87;1.64]  0.472                    
## kinhte:                                                                             0.143    0.143  
##     1.giau           14 (3.94%)   4 (28.6%)  10 (71.4%)        Ref.        Ref.                     
##     2.kha            22 (6.20%)   2 (9.09%)  20 (90.9%)  1.27 [0.89;1.82]  0.167                    
##     3.vua du         245 (69.0%) 54 (22.0%)  191 (78.0%) 1.09 [0.78;1.53]  0.566                    
##     4.kho khan       74 (20.8%)  23 (31.1%)  51 (68.9%)  0.96 [0.67;1.39]  0.879                    
## as.factor.thamnien.:                                                                0.014    0.014  
##     <1 nam           29 (8.17%)  12 (41.4%)  17 (58.6%)        Ref.        Ref.                     
##     >1-5nam          163 (45.9%) 46 (28.2%)  117 (71.8%) 1.22 [0.89;1.69]  0.169                    
##     >10-15nam        35 (9.86%)   6 (17.1%)  29 (82.9%)  1.41 [1.01;1.99]  0.038                    
##     >15-20 nam        9 (2.54%)   2 (22.2%)   7 (77.8%)  1.33 [0.83;2.11]  0.336                    
##     >20 nam           6 (1.69%)   1 (16.7%)   5 (83.3%)  1.42 [0.89;2.28]  0.303                    
##     >5-10nam         113 (31.8%) 16 (14.2%)  97 (85.8%)  1.46 [1.07;2.01]  0.003                    
## ban:                                                                                0.912    0.912  
##     can lam sang     67 (18.9%)  15 (22.4%)  52 (77.6%)        Ref.        Ref.                     
##     lam sang         224 (63.1%) 54 (24.1%)  170 (75.9%) 0.98 [0.84;1.13]  0.785                    
##     phong            64 (18.0%)  14 (21.9%)  50 (78.1%)  1.01 [0.84;1.21]  0.946                    
## nhiemvu:                                                                            0.867    0.867  
##     can lam sang     60 (16.9%)  13 (21.7%)  47 (78.3%)        Ref.        Ref.                     
##     cham soc         142 (40.0%) 33 (23.2%)  109 (76.8%) 0.98 [0.83;1.15]  0.821                    
##     chuyenvien       66 (18.6%)  14 (21.2%)  52 (78.8%)  1.01 [0.84;1.21]  0.950                    
##     dieu tri         87 (24.5%)  23 (26.4%)  64 (73.6%)  0.94 [0.78;1.13]  0.519                    
## mucdogjs_2:                                                                        <0.001   <0.001  
##     0.kohailong      48 (13.5%)  37 (77.1%)  11 (22.9%)        Ref.        Ref.                     
##     1.hailong        307 (86.5%) 46 (15.0%)  261 (85.0%) 3.71 [2.20;6.25]  0.000                    
## outuwes_3:                                                                         <0.001   <0.001  
##     0.gan ket        37 (10.4%)   37 (100%)   0 (0.00%)        Ref.        Ref.                     
##     1.TB gan ket     133 (37.5%) 46 (34.6%)  87 (65.4%)      . [.;.]      <0.001                    
##     2. Gan ket cao   185 (52.1%)  0 (0.00%)  185 (100%)      . [.;.]       0.000                    
## outgjs_3:                                                                          <0.001   <0.001  
##     0.hai long       48 (13.5%)  37 (77.1%)  11 (22.9%)        Ref.        Ref.                     
##     1.hai long TB    92 (25.9%)  26 (28.3%)  66 (71.7%)  3.13 [1.83;5.34] <0.001                    
##     2.hai long cao   215 (60.6%) 20 (9.30%)  195 (90.7%) 3.96 [2.35;6.66]  0.000                    
## ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
export2md(kq_ganket, size = 13)
Summary descriptives table by groups of `mucdoUWES_2’
[ALL] 0.ko_ganket 1.gan ket RR p.ratio p.overall p.trend
N=355 N=83 N=272
gioi: 0.695 0.695
nam 124 (34.9%) 27 (21.8%) 97 (78.2%) Ref. Ref.
nu 231 (65.1%) 56 (24.2%) 175 (75.8%) 0.97 [0.86;1.09] 0.607
tuoi 32.1 (6.76) 29.9 (5.52) 32.7 (6.96) . [.;.] . <0.001 <0.001
tuoi_n: 0.002 0.002
1.<30 tuoi 158 (44.5%) 48 (30.4%) 110 (69.6%) Ref. Ref.
2.40-49 tuoi 144 (40.6%) 31 (21.5%) 113 (78.5%) 1.13 [0.99;1.29] 0.082
3.>50 tuoi 53 (14.9%) 4 (7.55%) 49 (92.5%) 1.33 [1.17;1.51] <0.001
dantoc: 0.511 0.511
khac 13 (3.66%) 4 (30.8%) 9 (69.2%) Ref. Ref.
kinh 342 (96.3%) 79 (23.1%) 263 (76.9%) 1.11 [0.77;1.60] 0.524
noisong 1.09 (0.29) 1.12 (0.33) 1.08 (0.27) 0.89 [0.70;1.13] 0.335 0.319 0.319
noio: 0.366 0.366
gia dinh 202 (56.9%) 42 (20.8%) 160 (79.2%) Ref. Ref.
nguoi quen 15 (4.23%) 3 (20.0%) 12 (80.0%) 1.01 [0.78;1.31] 0.984
tro 138 (38.9%) 38 (27.5%) 100 (72.5%) 0.91 [0.81;1.04] 0.154
tongiao: 0.128 0.128
khong dao 274 (77.2%) 70 (25.5%) 204 (74.5%) Ref. Ref.
phat giao 58 (16.3%) 11 (19.0%) 47 (81.0%) 1.09 [0.94;1.26] 0.295
thien chua 23 (6.48%) 2 (8.70%) 21 (91.3%) 1.23 [1.06;1.42] 0.063
hocvan: 0.107 0.107
1.Trung-cap 39 (11.0%) 11 (28.2%) 28 (71.8%) Ref. Ref.
2.CD-DH 277 (78.0%) 68 (24.5%) 209 (75.5%) 1.05 [0.85;1.29] 0.616
3.SDH 39 (11.0%) 4 (10.3%) 35 (89.7%) 1.25 [1.00;1.56] 0.051
honnhan: 0.049 0.049
chua ket hon 152 (42.8%) 44 (28.9%) 108 (71.1%) Ref. Ref.
Da ket hon 196 (55.2%) 39 (19.9%) 157 (80.1%) 1.13 [1.00;1.28] 0.052
Ly hon 7 (1.97%) 0 (0.00%) 7 (100%) 1.41 [1.27;1.56] 0.098
socon: 0.107 0.107
0.con 198 (55.8%) 56 (28.3%) 142 (71.7%) Ref. Ref.
1.con 82 (23.1%) 15 (18.3%) 67 (81.7%) 1.14 [1.00;1.30] 0.080
2.con 68 (19.2%) 11 (16.2%) 57 (83.8%) 1.17 [1.02;1.34] 0.045
3.con 7 (1.97%) 1 (14.3%) 6 (85.7%) 1.20 [0.87;1.64] 0.472
kinhte: 0.143 0.143
1.giau 14 (3.94%) 4 (28.6%) 10 (71.4%) Ref. Ref.
2.kha 22 (6.20%) 2 (9.09%) 20 (90.9%) 1.27 [0.89;1.82] 0.167
3.vua du 245 (69.0%) 54 (22.0%) 191 (78.0%) 1.09 [0.78;1.53] 0.566
4.kho khan 74 (20.8%) 23 (31.1%) 51 (68.9%) 0.96 [0.67;1.39] 0.879
as.factor.thamnien.: 0.014 0.014
<1 nam 29 (8.17%) 12 (41.4%) 17 (58.6%) Ref. Ref.
>1-5nam 163 (45.9%) 46 (28.2%) 117 (71.8%) 1.22 [0.89;1.69] 0.169
>10-15nam 35 (9.86%) 6 (17.1%) 29 (82.9%) 1.41 [1.01;1.99] 0.038
>15-20 nam 9 (2.54%) 2 (22.2%) 7 (77.8%) 1.33 [0.83;2.11] 0.336
>20 nam 6 (1.69%) 1 (16.7%) 5 (83.3%) 1.42 [0.89;2.28] 0.303
>5-10nam 113 (31.8%) 16 (14.2%) 97 (85.8%) 1.46 [1.07;2.01] 0.003
ban: 0.912 0.912
can lam sang 67 (18.9%) 15 (22.4%) 52 (77.6%) Ref. Ref.
lam sang 224 (63.1%) 54 (24.1%) 170 (75.9%) 0.98 [0.84;1.13] 0.785
phong 64 (18.0%) 14 (21.9%) 50 (78.1%) 1.01 [0.84;1.21] 0.946
nhiemvu: 0.867 0.867
can lam sang 60 (16.9%) 13 (21.7%) 47 (78.3%) Ref. Ref.
cham soc 142 (40.0%) 33 (23.2%) 109 (76.8%) 0.98 [0.83;1.15] 0.821
chuyenvien 66 (18.6%) 14 (21.2%) 52 (78.8%) 1.01 [0.84;1.21] 0.950
dieu tri 87 (24.5%) 23 (26.4%) 64 (73.6%) 0.94 [0.78;1.13] 0.519
mucdogjs_2: <0.001 <0.001
0.kohailong 48 (13.5%) 37 (77.1%) 11 (22.9%) Ref. Ref.
1.hailong 307 (86.5%) 46 (15.0%) 261 (85.0%) 3.71 [2.20;6.25] 0.000
outuwes_3: <0.001 <0.001
0.gan ket 37 (10.4%) 37 (100%) 0 (0.00%) Ref. Ref.
1.TB gan ket 133 (37.5%) 46 (34.6%) 87 (65.4%) . [.;.] <0.001
  1. Gan ket cao
185 (52.1%) 0 (0.00%) 185 (100%) . [.;.] 0.000
outgjs_3: <0.001 <0.001
0.hai long 48 (13.5%) 37 (77.1%) 11 (22.9%) Ref. Ref.
1.hai long TB 92 (25.9%) 26 (28.3%) 66 (71.7%) 3.13 [1.83;5.34] <0.001
2.hai long cao 215 (60.6%) 20 (9.30%) 195 (90.7%) 3.96 [2.35;6.66] 0.000
kq_hailong = descrTable(mucdogjs_2 ~., data=dat.1,
                        byrow = T, riskratio = T, 
                        show.ratio = T, digits.ratio = 2, show.all = T,
                        show.p.trend = T, method = 1, 
                        compute.ratio = T, ref =1)
## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect

## Warning in chisq.test(xx, correct = FALSE): Chi-squared approximation may be
## incorrect
kq_hailong
## 
## --------Summary descriptives table by 'mucdogjs_2'---------
## 
## ___________________________________________________________________________________________________ 
##                         [ALL]    0.kohailong  1.hailong         RR        p.ratio p.overall p.trend 
##                         N=355       N=48        N=307                                               
## ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯ 
## gioi:                                                                               0.680    0.680  
##     nam              124 (34.9%) 15 (12.1%)  109 (87.9%)       Ref.        Ref.                     
##     nu               231 (65.1%) 33 (14.3%)  198 (85.7%) 0.98 [0.90;1.06]  0.576                    
## tuoi                 32.1 (6.76) 29.6 (5.35) 32.5 (6.88)     . [.;.]         .      0.002    0.002  
## tuoi_n:                                                                             0.003    0.003  
##     1.<30 tuoi       158 (44.5%) 32 (20.3%)  126 (79.7%)       Ref.        Ref.                     
##     2.40-49 tuoi     144 (40.6%) 13 (9.03%)  131 (91.0%) 1.14 [1.04;1.25]  0.006                    
##     3.>50 tuoi       53 (14.9%)   3 (5.66%)  50 (94.3%)  1.18 [1.07;1.31]  0.010                    
## dantoc:                                                                             1.000    1.000  
##     khac             13 (3.66%)   1 (7.69%)  12 (92.3%)        Ref.        Ref.                     
##     kinh             342 (96.3%) 47 (13.7%)  295 (86.3%) 0.93 [0.79;1.10]  0.601                    
## noisong              1.09 (0.29) 1.12 (0.33) 1.08 (0.28)     . [.;.]         .      0.431    0.431  
## noio:                                                                               0.048    0.048  
##     gia dinh         202 (56.9%) 20 (9.90%)  182 (90.1%)       Ref.        Ref.                     
##     nguoi quen       15 (4.23%)   2 (13.3%)  13 (86.7%)  0.96 [0.78;1.18]  0.647                    
##     tro              138 (38.9%) 26 (18.8%)  112 (81.2%) 0.90 [0.82;0.99]  0.020                    
## tongiao:                                                                            0.205    0.205  
##     khong dao        274 (77.2%) 42 (15.3%)  232 (84.7%)       Ref.        Ref.                     
##     phat giao        58 (16.3%)   4 (6.90%)  54 (93.1%)  1.10 [1.01;1.20]  0.084                    
##     thien chua       23 (6.48%)   2 (8.70%)  21 (91.3%)  1.08 [0.94;1.24]  0.421                    
## hocvan:                                                                             0.979    0.979  
##     1.Trung-cap      39 (11.0%)   5 (12.8%)  34 (87.2%)        Ref.        Ref.                     
##     2.CD-DH          277 (78.0%) 38 (13.7%)  239 (86.3%) 0.99 [0.87;1.13]  0.915                    
##     3.SDH            39 (11.0%)   5 (12.8%)  34 (87.2%)  1.00 [0.84;1.19]  1.000                    
## honnhan:                                                                            0.028    0.028  
##     chua ket hon     152 (42.8%) 29 (19.1%)  123 (80.9%)       Ref.        Ref.                     
##     Da ket hon       196 (55.2%) 19 (9.69%)  177 (90.3%) 1.12 [1.02;1.22]  0.013                    
##     Ly hon            7 (1.97%)   0 (0.00%)   7 (100%)   1.24 [1.14;1.33]  0.237                    
## socon:                                                                              0.006    0.006  
##     0.con            198 (55.8%) 38 (19.2%)  160 (80.8%)       Ref.        Ref.                     
##     1.con            82 (23.1%)   5 (6.10%)  77 (93.9%)  1.16 [1.06;1.27]  0.004                    
##     2.con            68 (19.2%)   5 (7.35%)  63 (92.6%)  1.15 [1.04;1.26]  0.018                    
##     3.con             7 (1.97%)   0 (0.00%)   7 (100%)   1.24 [1.16;1.32]  0.232                    
## kinhte:                                                                             0.198    0.198  
##     1.giau           14 (3.94%)   3 (21.4%)  11 (78.6%)        Ref.        Ref.                     
##     2.kha            22 (6.20%)   1 (4.55%)  21 (95.5%)  1.21 [0.91;1.62]  0.170                    
##     3.vua du         245 (69.0%) 30 (12.2%)  215 (87.8%) 1.12 [0.85;1.47]  0.344                    
##     4.kho khan       74 (20.8%)  14 (18.9%)  60 (81.1%)  1.03 [0.77;1.39]  0.806                    
## as.factor.thamnien.:                                                                0.017    0.017  
##     <1 nam           29 (8.17%)   4 (13.8%)  25 (86.2%)        Ref.        Ref.                     
##     >1-5nam          163 (45.9%) 33 (20.2%)  130 (79.8%) 0.93 [0.78;1.09]  0.440                    
##     >10-15nam        35 (9.86%)   1 (2.86%)  34 (97.1%)  1.13 [0.96;1.32]  0.140                    
##     >15-20 nam        9 (2.54%)   1 (11.1%)   8 (88.9%)  1.03 [0.78;1.35]  0.899                    
##     >20 nam           6 (1.69%)   0 (0.00%)   6 (100%)   1.16 [1.00;1.34]  0.454                    
##     >5-10nam         113 (31.8%)  9 (7.96%)  104 (92.0%) 1.07 [0.91;1.25]  0.355                    
## ban:                                                                                0.486    0.486  
##     can lam sang     67 (18.9%)  11 (16.4%)  56 (83.6%)        Ref.        Ref.                     
##     lam sang         224 (63.1%) 31 (13.8%)  193 (86.2%) 1.03 [0.92;1.16]  0.593                    
##     phong            64 (18.0%)   6 (9.38%)  58 (90.6%)  1.08 [0.95;1.24]  0.245                    
## nhiemvu:                                                                            0.121    0.121  
##     can lam sang     60 (16.9%)  10 (16.7%)  50 (83.3%)        Ref.        Ref.                     
##     cham soc         142 (40.0%) 16 (11.3%)  126 (88.7%) 1.06 [0.94;1.21]  0.308                    
##     chuyenvien       66 (18.6%)   5 (7.58%)  61 (92.4%)  1.11 [0.97;1.27]  0.128                    
##     dieu tri         87 (24.5%)  17 (19.5%)  70 (80.5%)  0.97 [0.83;1.13]  0.671                    
## mucdoUWES_2:                                                                       <0.001   <0.001  
##     0.ko_ganket      83 (23.4%)  37 (44.6%)  46 (55.4%)        Ref.        Ref.                     
##     1.gan ket        272 (76.6%) 11 (4.04%)  261 (96.0%) 1.73 [1.43;2.10]  0.000                    
## outuwes_3:                                                                         <0.001   <0.001  
##     0.gan ket        37 (10.4%)  23 (62.2%)  14 (37.8%)        Ref.        Ref.                     
##     1.TB gan ket     133 (37.5%) 22 (16.5%)  111 (83.5%) 2.21 [1.45;3.36] <0.001                    
##     2. Gan ket cao   185 (52.1%)  3 (1.62%)  182 (98.4%) 2.60 [1.72;3.93]  0.000                    
## outgjs_3:                                                                          <0.001   <0.001  
##     0.hai long       48 (13.5%)   48 (100%)   0 (0.00%)        Ref.        Ref.                     
##     1.hai long TB    92 (25.9%)   0 (0.00%)   92 (100%)      . [.;.]       0.000                    
##     2.hai long cao   215 (60.6%)  0 (0.00%)  215 (100%)      . [.;.]       0.000                    
## ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
export2md(kq_hailong, size = 13)
Summary descriptives table by groups of `mucdogjs_2’
[ALL] 0.kohailong 1.hailong RR p.ratio p.overall p.trend
N=355 N=48 N=307
gioi: 0.680 0.680
nam 124 (34.9%) 15 (12.1%) 109 (87.9%) Ref. Ref.
nu 231 (65.1%) 33 (14.3%) 198 (85.7%) 0.98 [0.90;1.06] 0.576
tuoi 32.1 (6.76) 29.6 (5.35) 32.5 (6.88) . [.;.] . 0.002 0.002
tuoi_n: 0.003 0.003
1.<30 tuoi 158 (44.5%) 32 (20.3%) 126 (79.7%) Ref. Ref.
2.40-49 tuoi 144 (40.6%) 13 (9.03%) 131 (91.0%) 1.14 [1.04;1.25] 0.006
3.>50 tuoi 53 (14.9%) 3 (5.66%) 50 (94.3%) 1.18 [1.07;1.31] 0.010
dantoc: 1.000 1.000
khac 13 (3.66%) 1 (7.69%) 12 (92.3%) Ref. Ref.
kinh 342 (96.3%) 47 (13.7%) 295 (86.3%) 0.93 [0.79;1.10] 0.601
noisong 1.09 (0.29) 1.12 (0.33) 1.08 (0.28) . [.;.] . 0.431 0.431
noio: 0.048 0.048
gia dinh 202 (56.9%) 20 (9.90%) 182 (90.1%) Ref. Ref.
nguoi quen 15 (4.23%) 2 (13.3%) 13 (86.7%) 0.96 [0.78;1.18] 0.647
tro 138 (38.9%) 26 (18.8%) 112 (81.2%) 0.90 [0.82;0.99] 0.020
tongiao: 0.205 0.205
khong dao 274 (77.2%) 42 (15.3%) 232 (84.7%) Ref. Ref.
phat giao 58 (16.3%) 4 (6.90%) 54 (93.1%) 1.10 [1.01;1.20] 0.084
thien chua 23 (6.48%) 2 (8.70%) 21 (91.3%) 1.08 [0.94;1.24] 0.421
hocvan: 0.979 0.979
1.Trung-cap 39 (11.0%) 5 (12.8%) 34 (87.2%) Ref. Ref.
2.CD-DH 277 (78.0%) 38 (13.7%) 239 (86.3%) 0.99 [0.87;1.13] 0.915
3.SDH 39 (11.0%) 5 (12.8%) 34 (87.2%) 1.00 [0.84;1.19] 1.000
honnhan: 0.028 0.028
chua ket hon 152 (42.8%) 29 (19.1%) 123 (80.9%) Ref. Ref.
Da ket hon 196 (55.2%) 19 (9.69%) 177 (90.3%) 1.12 [1.02;1.22] 0.013
Ly hon 7 (1.97%) 0 (0.00%) 7 (100%) 1.24 [1.14;1.33] 0.237
socon: 0.006 0.006
0.con 198 (55.8%) 38 (19.2%) 160 (80.8%) Ref. Ref.
1.con 82 (23.1%) 5 (6.10%) 77 (93.9%) 1.16 [1.06;1.27] 0.004
2.con 68 (19.2%) 5 (7.35%) 63 (92.6%) 1.15 [1.04;1.26] 0.018
3.con 7 (1.97%) 0 (0.00%) 7 (100%) 1.24 [1.16;1.32] 0.232
kinhte: 0.198 0.198
1.giau 14 (3.94%) 3 (21.4%) 11 (78.6%) Ref. Ref.
2.kha 22 (6.20%) 1 (4.55%) 21 (95.5%) 1.21 [0.91;1.62] 0.170
3.vua du 245 (69.0%) 30 (12.2%) 215 (87.8%) 1.12 [0.85;1.47] 0.344
4.kho khan 74 (20.8%) 14 (18.9%) 60 (81.1%) 1.03 [0.77;1.39] 0.806
as.factor.thamnien.: 0.017 0.017
<1 nam 29 (8.17%) 4 (13.8%) 25 (86.2%) Ref. Ref.
>1-5nam 163 (45.9%) 33 (20.2%) 130 (79.8%) 0.93 [0.78;1.09] 0.440
>10-15nam 35 (9.86%) 1 (2.86%) 34 (97.1%) 1.13 [0.96;1.32] 0.140
>15-20 nam 9 (2.54%) 1 (11.1%) 8 (88.9%) 1.03 [0.78;1.35] 0.899
>20 nam 6 (1.69%) 0 (0.00%) 6 (100%) 1.16 [1.00;1.34] 0.454
>5-10nam 113 (31.8%) 9 (7.96%) 104 (92.0%) 1.07 [0.91;1.25] 0.355
ban: 0.486 0.486
can lam sang 67 (18.9%) 11 (16.4%) 56 (83.6%) Ref. Ref.
lam sang 224 (63.1%) 31 (13.8%) 193 (86.2%) 1.03 [0.92;1.16] 0.593
phong 64 (18.0%) 6 (9.38%) 58 (90.6%) 1.08 [0.95;1.24] 0.245
nhiemvu: 0.121 0.121
can lam sang 60 (16.9%) 10 (16.7%) 50 (83.3%) Ref. Ref.
cham soc 142 (40.0%) 16 (11.3%) 126 (88.7%) 1.06 [0.94;1.21] 0.308
chuyenvien 66 (18.6%) 5 (7.58%) 61 (92.4%) 1.11 [0.97;1.27] 0.128
dieu tri 87 (24.5%) 17 (19.5%) 70 (80.5%) 0.97 [0.83;1.13] 0.671
mucdoUWES_2: <0.001 <0.001
0.ko_ganket 83 (23.4%) 37 (44.6%) 46 (55.4%) Ref. Ref.
1.gan ket 272 (76.6%) 11 (4.04%) 261 (96.0%) 1.73 [1.43;2.10] 0.000
outuwes_3: <0.001 <0.001
0.gan ket 37 (10.4%) 23 (62.2%) 14 (37.8%) Ref. Ref.
1.TB gan ket 133 (37.5%) 22 (16.5%) 111 (83.5%) 2.21 [1.45;3.36] <0.001
  1. Gan ket cao
185 (52.1%) 3 (1.62%) 182 (98.4%) 2.60 [1.72;3.93] 0.000
outgjs_3: <0.001 <0.001
0.hai long 48 (13.5%) 48 (100%) 0 (0.00%) Ref. Ref.
1.hai long TB 92 (25.9%) 0 (0.00%) 92 (100%) . [.;.] 0.000
2.hai long cao 215 (60.6%) 0 (0.00%) 215 (100%) . [.;.] 0.000
kq_ganket_3 = descrTable(outuwes_3 ~.,dat.1, show.p.mul=TRUE,
                         byrow = T, riskratio = T, 
                         show.ratio = T, digits.ratio = 2,
                         show.all = T,
                         compute.ratio = T, p.corrected = T)
kq_ganket_3
## 
## --------Summary descriptives table by 'outuwes_3'---------
## 
## _____________________________________________________________________________________________________________________________________________________________________________ 
##                         [ALL]     0.gan ket  1.TB gan ket 2. Gan ket cao p.overall p.0.gan ket vs 1.TB gan ket p.0.gan ket vs 2. Gan ket cao p.1.TB gan ket vs 2. Gan ket cao 
##                         N=355       N=37        N=133         N=185                                                                                                           
## ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯ 
## gioi:                                                                      0.134              0.302                        0.401                          0.302               
##     nam              124 (34.9%)  9 (7.26%)   54 (43.5%)    61 (49.2%)                                                                                                        
##     nu               231 (65.1%) 28 (12.1%)   79 (34.2%)   124 (53.7%)                                                                                                        
## tuoi                 32.1 (6.76) 28.6 (3.59) 31.6 (6.59)   33.1 (7.10)     0.001              0.041                        0.001                          0.110               
## tuoi_n:                                                                    0.002              0.016                        0.004                          0.092               
##     1.<30 tuoi       158 (44.5%) 25 (15.8%)   59 (37.3%)    74 (46.8%)                                                                                                        
##     2.40-49 tuoi     144 (40.6%) 12 (8.33%)   59 (41.0%)    73 (50.7%)                                                                                                        
##     3.>50 tuoi       53 (14.9%)   0 (0.00%)   15 (28.3%)    38 (71.7%)                                                                                                        
## dantoc:                                                                    0.770              0.970                        0.970                          1.000               
##     khac             13 (3.66%)   2 (15.4%)   5 (38.5%)     6 (46.2%)                                                                                                         
##     kinh             342 (96.3%) 35 (10.2%)  128 (37.4%)   179 (52.3%)                                                                                                        
## noisong              1.09 (0.29) 1.14 (0.35) 1.11 (0.31)   1.07 (0.26)     0.339              0.841                        0.421                          0.531               
## noio:                                                                      0.801              0.760                        0.760                          0.760               
##     gia dinh         202 (56.9%) 19 (9.41%)   73 (36.1%)   110 (54.5%)                                                                                                        
##     nguoi quen       15 (4.23%)   2 (13.3%)   5 (33.3%)     8 (53.3%)                                                                                                         
##     tro              138 (38.9%) 16 (11.6%)   55 (39.9%)    67 (48.6%)                                                                                                        
## tongiao:                                                                   0.592              0.762                        0.762                          0.762               
##     khong dao        274 (77.2%) 31 (11.3%)  102 (37.2%)   141 (51.5%)                                                                                                        
##     phat giao        58 (16.3%)   4 (6.90%)   25 (43.1%)    29 (50.0%)                                                                                                        
##     thien chua       23 (6.48%)   2 (8.70%)   6 (26.1%)     15 (65.2%)                                                                                                        
## hocvan:                                                                    0.233              0.358                        0.358                          0.358               
##     1.Trung-cap      39 (11.0%)   3 (7.69%)   19 (48.7%)    17 (43.6%)                                                                                                        
##     2.CD-DH          277 (78.0%) 33 (11.9%)   98 (35.4%)   146 (52.7%)                                                                                                        
##     3.SDH            39 (11.0%)   1 (2.56%)   16 (41.0%)    22 (56.4%)                                                                                                        
## honnhan:                                                                   0.260              0.774                        0.417                          0.417               
##     chua ket hon     152 (42.8%) 19 (12.5%)   62 (40.8%)    71 (46.7%)                                                                                                        
##     Da ket hon       196 (55.2%) 18 (9.18%)   70 (35.7%)   108 (55.1%)                                                                                                        
##     Ly hon            7 (1.97%)   0 (0.00%)   1 (14.3%)     6 (85.7%)                                                                                                         
## socon:                                                                       .                0.020                        0.020                          0.505               
##     0.con            198 (55.8%) 30 (15.2%)   71 (35.9%)    97 (49.0%)                                                                                                        
##     1.con            82 (23.1%)   5 (6.10%)   31 (37.8%)    46 (56.1%)                                                                                                        
##     2.con            68 (19.2%)   2 (2.94%)   30 (44.1%)    36 (52.9%)                                                                                                        
##     3.con             7 (1.97%)   0 (0.00%)   1 (14.3%)     6 (85.7%)                                                                                                         
## kinhte:                                                                    0.340              0.780                        0.735                          0.499               
##     1.giau           14 (3.94%)   1 (7.14%)   7 (50.0%)     6 (42.9%)                                                                                                         
##     2.kha            22 (6.20%)   1 (4.55%)   10 (45.5%)    11 (50.0%)                                                                                                        
##     3.vua du         245 (69.0%) 25 (10.2%)   83 (33.9%)   137 (55.9%)                                                                                                        
##     4.kho khan       74 (20.8%)  10 (13.5%)   33 (44.6%)    31 (41.9%)                                                                                                        
## as.factor.thamnien.:                                                         .                0.032                        0.019                          0.337               
##     <1 nam           29 (8.17%)   2 (6.90%)   16 (55.2%)    11 (37.9%)                                                                                                        
##     >1-5nam          163 (45.9%) 28 (17.2%)   56 (34.4%)    79 (48.5%)                                                                                                        
##     >10-15nam        35 (9.86%)   3 (8.57%)   15 (42.9%)    17 (48.6%)                                                                                                        
##     >15-20 nam        9 (2.54%)   0 (0.00%)   4 (44.4%)     5 (55.6%)                                                                                                         
##     >20 nam           6 (1.69%)   0 (0.00%)   3 (50.0%)     3 (50.0%)                                                                                                         
##     >5-10nam         113 (31.8%)  4 (3.54%)   39 (34.5%)    70 (61.9%)                                                                                                        
## ban:                                                                       0.647              0.589                        0.589                          0.589               
##     can lam sang     67 (18.9%)   9 (13.4%)   22 (32.8%)    36 (53.7%)                                                                                                        
##     lam sang         224 (63.1%) 23 (10.3%)   89 (39.7%)   112 (50.0%)                                                                                                        
##     phong            64 (18.0%)   5 (7.81%)   22 (34.4%)    37 (57.8%)                                                                                                        
## nhiemvu:                                                                   0.103              0.158                        0.540                          0.158               
##     can lam sang     60 (16.9%)   8 (13.3%)   18 (30.0%)    34 (56.7%)                                                                                                        
##     cham soc         142 (40.0%) 19 (13.4%)   45 (31.7%)    78 (54.9%)                                                                                                        
##     chuyenvien       66 (18.6%)   4 (6.06%)   28 (42.4%)    34 (51.5%)                                                                                                        
##     dieu tri         87 (24.5%)   6 (6.90%)   42 (48.3%)    39 (44.8%)                                                                                                        
## mucdoUWES_2:                                                              <0.001             <0.001                       <0.001                          <0.001              
##     0.ko_ganket      83 (23.4%)  37 (44.6%)   46 (55.4%)    0 (0.00%)                                                                                                         
##     1.gan ket        272 (76.6%)  0 (0.00%)   87 (32.0%)   185 (68.0%)                                                                                                        
## mucdogjs_2:                                                               <0.001             <0.001                       <0.001                          <0.001              
##     0.kohailong      48 (13.5%)  23 (47.9%)   22 (45.8%)    3 (6.25%)                                                                                                         
##     1.hailong        307 (86.5%) 14 (4.56%)  111 (36.2%)   182 (59.3%)                                                                                                        
## outgjs_3:                                                                 <0.001             <0.001                       <0.001                          <0.001              
##     0.hai long       48 (13.5%)  23 (47.9%)   22 (45.8%)    3 (6.25%)                                                                                                         
##     1.hai long TB    92 (25.9%)  10 (10.9%)   49 (53.3%)    33 (35.9%)                                                                                                        
##     2.hai long cao   215 (60.6%)  4 (1.86%)   62 (28.8%)   149 (69.3%)                                                                                                        
## ¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯¯
export2md(kq_ganket_3, size = 13)
Summary descriptives table by groups of `outuwes_3’
[ALL] 0.gan ket 1.TB gan ket
  1. Gan ket cao
p.overall p.0.gan ket vs 1.TB gan ket p.0.gan ket vs 2. Gan ket cao p.1.TB gan ket vs 2. Gan ket cao
N=355 N=37 N=133 N=185
gioi: 0.134 0.302 0.401 0.302
nam 124 (34.9%) 9 (7.26%) 54 (43.5%) 61 (49.2%)
nu 231 (65.1%) 28 (12.1%) 79 (34.2%) 124 (53.7%)
tuoi 32.1 (6.76) 28.6 (3.59) 31.6 (6.59) 33.1 (7.10) 0.001 0.041 0.001 0.110
tuoi_n: 0.002 0.016 0.004 0.092
1.<30 tuoi 158 (44.5%) 25 (15.8%) 59 (37.3%) 74 (46.8%)
2.40-49 tuoi 144 (40.6%) 12 (8.33%) 59 (41.0%) 73 (50.7%)
3.>50 tuoi 53 (14.9%) 0 (0.00%) 15 (28.3%) 38 (71.7%)
dantoc: 0.770 0.970 0.970 1.000
khac 13 (3.66%) 2 (15.4%) 5 (38.5%) 6 (46.2%)
kinh 342 (96.3%) 35 (10.2%) 128 (37.4%) 179 (52.3%)
noisong 1.09 (0.29) 1.14 (0.35) 1.11 (0.31) 1.07 (0.26) 0.339 0.841 0.421 0.531
noio: 0.801 0.760 0.760 0.760
gia dinh 202 (56.9%) 19 (9.41%) 73 (36.1%) 110 (54.5%)
nguoi quen 15 (4.23%) 2 (13.3%) 5 (33.3%) 8 (53.3%)
tro 138 (38.9%) 16 (11.6%) 55 (39.9%) 67 (48.6%)
tongiao: 0.592 0.762 0.762 0.762
khong dao 274 (77.2%) 31 (11.3%) 102 (37.2%) 141 (51.5%)
phat giao 58 (16.3%) 4 (6.90%) 25 (43.1%) 29 (50.0%)
thien chua 23 (6.48%) 2 (8.70%) 6 (26.1%) 15 (65.2%)
hocvan: 0.233 0.358 0.358 0.358
1.Trung-cap 39 (11.0%) 3 (7.69%) 19 (48.7%) 17 (43.6%)
2.CD-DH 277 (78.0%) 33 (11.9%) 98 (35.4%) 146 (52.7%)
3.SDH 39 (11.0%) 1 (2.56%) 16 (41.0%) 22 (56.4%)
honnhan: 0.260 0.774 0.417 0.417
chua ket hon 152 (42.8%) 19 (12.5%) 62 (40.8%) 71 (46.7%)
Da ket hon 196 (55.2%) 18 (9.18%) 70 (35.7%) 108 (55.1%)
Ly hon 7 (1.97%) 0 (0.00%) 1 (14.3%) 6 (85.7%)
socon: . 0.020 0.020 0.505
0.con 198 (55.8%) 30 (15.2%) 71 (35.9%) 97 (49.0%)
1.con 82 (23.1%) 5 (6.10%) 31 (37.8%) 46 (56.1%)
2.con 68 (19.2%) 2 (2.94%) 30 (44.1%) 36 (52.9%)
3.con 7 (1.97%) 0 (0.00%) 1 (14.3%) 6 (85.7%)
kinhte: 0.340 0.780 0.735 0.499
1.giau 14 (3.94%) 1 (7.14%) 7 (50.0%) 6 (42.9%)
2.kha 22 (6.20%) 1 (4.55%) 10 (45.5%) 11 (50.0%)
3.vua du 245 (69.0%) 25 (10.2%) 83 (33.9%) 137 (55.9%)
4.kho khan 74 (20.8%) 10 (13.5%) 33 (44.6%) 31 (41.9%)
as.factor.thamnien.: . 0.032 0.019 0.337
<1 nam 29 (8.17%) 2 (6.90%) 16 (55.2%) 11 (37.9%)
>1-5nam 163 (45.9%) 28 (17.2%) 56 (34.4%) 79 (48.5%)
>10-15nam 35 (9.86%) 3 (8.57%) 15 (42.9%) 17 (48.6%)
>15-20 nam 9 (2.54%) 0 (0.00%) 4 (44.4%) 5 (55.6%)
>20 nam 6 (1.69%) 0 (0.00%) 3 (50.0%) 3 (50.0%)
>5-10nam 113 (31.8%) 4 (3.54%) 39 (34.5%) 70 (61.9%)
ban: 0.647 0.589 0.589 0.589
can lam sang 67 (18.9%) 9 (13.4%) 22 (32.8%) 36 (53.7%)
lam sang 224 (63.1%) 23 (10.3%) 89 (39.7%) 112 (50.0%)
phong 64 (18.0%) 5 (7.81%) 22 (34.4%) 37 (57.8%)
nhiemvu: 0.103 0.158 0.540 0.158
can lam sang 60 (16.9%) 8 (13.3%) 18 (30.0%) 34 (56.7%)
cham soc 142 (40.0%) 19 (13.4%) 45 (31.7%) 78 (54.9%)
chuyenvien 66 (18.6%) 4 (6.06%) 28 (42.4%) 34 (51.5%)
dieu tri 87 (24.5%) 6 (6.90%) 42 (48.3%) 39 (44.8%)
mucdoUWES_2: <0.001 <0.001 <0.001 <0.001
0.ko_ganket 83 (23.4%) 37 (44.6%) 46 (55.4%) 0 (0.00%)
1.gan ket 272 (76.6%) 0 (0.00%) 87 (32.0%) 185 (68.0%)
mucdogjs_2: <0.001 <0.001 <0.001 <0.001
0.kohailong 48 (13.5%) 23 (47.9%) 22 (45.8%) 3 (6.25%)
1.hailong 307 (86.5%) 14 (4.56%) 111 (36.2%) 182 (59.3%)
outgjs_3: <0.001 <0.001 <0.001 <0.001
0.hai long 48 (13.5%) 23 (47.9%) 22 (45.8%) 3 (6.25%)
1.hai long TB 92 (25.9%) 10 (10.9%) 49 (53.3%) 33 (35.9%)
2.hai long cao 215 (60.6%) 4 (1.86%) 62 (28.8%) 149 (69.3%)
library(tables)
t.2 = tabular((factor(gioi) + factor(tuoi_n)+ factor(dantoc) 
               + factor(noio)+ factor(tongiao)+ factor(hocvan) + factor(honnhan)+ factor(socon)
               + factor(kinhte) + factor(thamnien)+ factor(ban)
               + factor(nhiemvu))~(uwesTong + gjsTong)*(n=1+ median + mean + sd))
toHTML(t.2,format="html", digits = 3)  
    uwesTong gjsTong
    n n
All median mean sd All median mean sd
factor(gioi) nam 124 41.0 39.1 9.63 124 40.0 38.8 6.41
nu 231 43.0 38.3 11.28 231 39.0 37.6 5.75
factor(tuoi_n) 1.<30 tuoi 158 39.5 36.6 11.75 158 39.0 36.8 6.64
2.40-49 tuoi 144 42.0 38.7 10.01 144 40.0 38.3 5.13
3.>50 tuoi 53 45.0 44.2 6.82 53 40.0 41.0 5.14
factor(dantoc) khac 13 36.0 36.5 10.88 13 38.0 36.2 5.66
kinh 342 42.0 38.7 10.73 342 40.0 38.1 6.02
factor(noio) gia dinh 202 43.0 39.4 10.64 202 40.0 38.9 5.66
nguoi quen 15 44.0 38.6 12.55 15 40.0 37.1 4.78
tro 138 39.5 37.5 10.63 138 39.0 36.8 6.42
factor(tongiao) khong dao 274 42.0 38.1 10.99 274 40.0 37.8 6.22
phat giao 58 41.0 39.6 9.80 58 40.0 39.5 4.26
thien chua 23 44.0 42.3 9.14 23 38.0 36.7 6.79
factor(hocvan) 1.Trung-cap 39 37.0 37.2 8.35 39 38.0 36.5 5.48
2.CD-DH 277 42.0 38.4 11.23 277 40.0 38.0 6.04
3.SDH 39 43.0 41.5 8.59 39 40.0 39.6 6.01
factor(honnhan) chua ket hon 152 39.5 37.3 10.39 152 39.5 36.9 6.23
Da ket hon 196 43.0 39.3 10.97 196 40.0 38.7 5.67
Ly hon 7 45.0 45.9 6.57 7 46.0 43.9 4.74
factor(socon) 0.con 198 40.5 37.1 11.16 198 40.0 36.7 6.48
1.con 82 42.0 39.7 10.33 82 40.0 39.0 4.89
2.con 68 43.0 40.7 9.18 68 40.0 40.4 4.90
3.con 7 49.0 46.4 10.08 7 40.0 40.1 5.15
factor(kinhte) 1.giau 14 38.5 38.1 9.49 14 40.0 38.7 5.20
2.kha 22 41.5 40.1 9.87 22 40.0 40.5 3.96
3.vua du 245 43.0 39.0 10.92 245 40.0 38.2 6.16
4.kho khan 74 36.5 36.8 10.51 74 38.0 36.7 5.92
factor(thamnien) <1 nam 29 36.0 34.7 11.06 29 39.0 37.7 4.80
>1-5nam 163 41.0 37.1 11.52 163 39.0 36.5 6.68
>10-15nam 35 41.0 39.9 11.02 35 40.0 39.9 5.09
>15-20 nam 9 45.0 42.1 9.03 9 40.0 40.4 6.67
>20 nam 6 44.0 41.3 7.74 6 40.0 40.7 3.67
>5-10nam 113 44.0 40.9 9.02 113 40.0 39.4 5.01
factor(ban) can lam sang 67 44.0 38.7 10.78 67 39.0 37.7 7.48
lam sang 224 41.5 38.0 10.82 224 40.0 37.5 5.45
phong 64 43.5 40.5 10.24 64 40.0 40.0 5.85
factor(nhiemvu) can lam sang 60 44.0 39.0 10.54 60 39.5 38.3 6.52
cham soc 142 44.0 38.1 11.97 142 40.0 38.0 5.93
chuyenvien 66 42.0 39.9 9.78 66 40.0 39.4 5.83
dieu tri 87 37.0 38.1 9.37 87 39.0 36.9 5.76
t.3 = tabular((factor(gioi) + factor(tuoi_n)+ factor(dantoc) 
               + factor(noio)+ factor(tongiao)+ factor(hocvan) + factor(honnhan)+ factor(socon)
               + factor(kinhte) + factor(thamnien)+ factor(ban)
               + factor(nhiemvu))~(sucsong + conghien + sayme)*(n=1+ mean + sd))
 toHTML(t.3, format="html", digits = 3)
    sucsong conghien sayme
    n n n
All mean sd All mean sd All mean sd
factor(gioi) nam 124 13.1 3.41 124 13.3 3.22 124 12.7 3.40
nu 231 13.0 4.09 231 13.2 3.96 231 12.1 3.85
factor(tuoi_n) 1.<30 tuoi 158 12.3 4.24 158 12.6 4.09 158 11.6 3.99
2.40-49 tuoi 144 13.1 3.57 144 13.2 3.49 144 12.4 3.49
3.>50 tuoi 53 14.9 2.69 53 15.1 2.34 53 14.2 2.63
factor(dantoc) khac 13 12.3 3.57 13 12.5 4.10 13 11.7 3.88
kinh 342 13.1 3.88 342 13.3 3.70 342 12.4 3.70
factor(noio) gia dinh 202 13.3 3.85 202 13.5 3.69 202 12.5 3.67
nguoi quen 15 13.0 3.84 15 13.3 4.03 15 12.3 4.88
tro 138 12.7 3.89 138 12.8 3.71 138 12.0 3.63
factor(tongiao) khong dao 274 12.8 3.96 274 13.1 3.78 274 12.2 3.76
phat giao 58 13.4 3.37 58 13.5 3.29 58 12.7 3.63
thien chua 23 14.7 3.51 23 14.7 3.70 23 12.9 3.29
factor(hocvan) 1.Trung-cap 39 12.6 3.12 39 12.7 2.75 39 11.9 3.06
2.CD-DH 277 13.0 4.05 277 13.2 3.92 277 12.2 3.85
3.SDH 39 13.8 3.11 39 14.1 2.87 39 13.6 2.93
factor(honnhan) chua ket hon 152 12.6 3.73 152 12.8 3.61 152 11.9 3.63
Da ket hon 196 13.3 3.97 196 13.5 3.79 196 12.6 3.73
Ly hon 7 15.4 2.15 7 16.3 1.38 7 14.1 3.93
factor(socon) 0.con 198 12.5 4.02 198 12.7 3.84 198 11.9 3.82
1.con 82 13.4 3.63 82 13.5 3.69 82 12.8 3.57
2.con 68 13.8 3.47 68 14.1 3.16 68 12.8 3.34
3.con 7 15.4 3.55 7 15.7 3.25 7 15.3 3.35
factor(kinhte) 1.giau 14 13.0 3.14 14 13.1 3.17 14 12.1 3.54
2.kha 22 13.6 3.38 22 13.8 3.25 22 12.7 3.71
3.vua du 245 13.2 3.95 245 13.4 3.80 245 12.5 3.71
4.kho khan 74 12.4 3.82 74 12.7 3.65 74 11.6 3.71
factor(thamnien) <1 nam 29 12.1 4.29 29 12.3 4.32 29 10.3 3.08
>1-5nam 163 12.4 4.07 163 12.6 3.94 163 12.1 3.93
>10-15nam 35 13.5 4.15 35 13.6 3.70 35 12.8 3.64
>15-20 nam 9 14.3 3.32 9 14.4 2.79 9 13.3 4.09
>20 nam 6 13.2 3.76 6 14.2 3.19 6 14.0 2.00
>5-10nam 113 13.9 3.19 113 14.1 3.11 113 12.9 3.38
factor(ban) can lam sang 67 13.2 4.05 67 13.5 3.81 67 12.0 3.59
lam sang 224 12.8 3.86 224 12.9 3.76 224 12.3 3.70
phong 64 13.7 3.64 64 14.0 3.37 64 12.9 3.83
factor(nhiemvu) can lam sang 60 13.3 3.97 60 13.6 3.70 60 12.1 3.56
cham soc 142 12.8 4.24 142 12.9 4.11 142 12.4 4.07
chuyenvien 66 13.6 3.53 66 13.8 3.28 66 12.6 3.67
dieu tri 87 12.8 3.36 87 13.0 3.31 87 12.2 3.22
dat.2 = data.frame(gioi, tuoi_n,dantoc, noio, tongiao, hocvan,
                   honnhan, socon, kinhte, thamnien, 
                   ban,nhiemvu, sucsong)

dat.3 = data.frame(gioi, tuoi_n,dantoc, noio, tongiao, hocvan,
                   honnhan, socon, kinhte, thamnien, ban,nhiemvu, conghien) 

dat.4 = data.frame(gioi, tuoi_n, dantoc, noio, tongiao, hocvan,
                   honnhan, socon, kinhte, thamnien, ban, sayme)

dat.5 = data.frame(gioi, tuoi_n,dantoc, noio, tongiao, hocvan,
                   honnhan, socon, kinhte, thamnien, ban,uwesTong)

dat.6 = data.frame(gioi, tuoi_n,dantoc, noio, tongiao, hocvan,
                   honnhan, socon, kinhte, thamnien, ban, gjsTong)

library(stats)
lm(sucsong ~ ., data = dat.2)%>% 
  summary 
## 
## Call:
## lm(formula = sucsong ~ ., data = dat.2)
## 
## Residuals:
##      Min       1Q   Median       3Q      Max 
## -11.5477  -2.4248   0.6641   2.6832   6.4775 
## 
## Coefficients:
##                    Estimate Std. Error t value Pr(>|t|)    
## (Intercept)        10.47444    1.84615   5.674 3.09e-08 ***
## gioinu             -0.33986    0.45434  -0.748   0.4550    
## tuoi_n2.40-49 tuoi  0.23757    0.54912   0.433   0.6656    
## tuoi_n3.>50 tuoi    2.14656    0.85063   2.524   0.0121 *  
## dantockinh          0.79293    1.12973   0.702   0.4833    
## noionguoi quen      0.41271    1.07869   0.383   0.7023    
## noiotro             0.28149    0.49072   0.574   0.5666    
## tongiaophat giao    0.59103    0.58700   1.007   0.3147    
## tongiaothien chua   2.15110    0.87573   2.456   0.0146 *  
## hocvan2.CD-DH       0.45307    0.69439   0.652   0.5146    
## hocvan3.SDH         0.92257    0.97975   0.942   0.3471    
## honnhanDa ket hon  -0.42372    0.64542  -0.657   0.5120    
## honnhanLy hon       2.42555    1.56095   1.554   0.1212    
## socon1.con          0.58484    0.72518   0.806   0.4206    
## socon2.con          0.39968    0.85023   0.470   0.6386    
## socon3.con          2.02116    1.62475   1.244   0.2144    
## kinhte2.kha         1.17147    1.38448   0.846   0.3981    
## kinhte3.vua du      0.57995    1.12337   0.516   0.6060    
## kinhte4.kho khan    0.08177    1.18545   0.069   0.9451    
## thamnien>1-5nam     0.12332    0.79414   0.155   0.8767    
## thamnien>10-15nam   0.52581    1.09257   0.481   0.6307    
## thamnien>15-20 nam  0.25410    1.67957   0.151   0.8798    
## thamnien>20 nam    -1.35176    1.94428  -0.695   0.4874    
## thamnien>5-10nam    0.96438    0.88638   1.088   0.2774    
## banlam sang        -0.07509    1.46780  -0.051   0.9592    
## banphong            0.50798    1.30747   0.389   0.6979    
## nhiemvucham soc    -0.10668    1.51608  -0.070   0.9439    
## nhiemvuchuyenvien  -0.56911    1.32265  -0.430   0.6673    
## nhiemvudieu tri    -0.30012    1.61010  -0.186   0.8522    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 3.807 on 326 degrees of freedom
## Multiple R-squared:  0.1058, Adjusted R-squared:  0.02901 
## F-statistic: 1.378 on 28 and 326 DF,  p-value: 0.1005
library(sjPlot)
## Install package "strengejacke" from GitHub (`devtools::install_github("strengejacke/strengejacke")`) to load all sj-packages at once!
library(sjmisc)
library(sjlabelled)
library(glmmTMB)

m1 = lm(sucsong ~ ., data = dat.2) 
m2 = lm(conghien ~., data = dat.3) 
m3 = lm(sayme ~ ., data = dat.4) 
m4 = lm(uwesTong ~ ., data = dat.5)
m5 = lm(gjsTong ~ ., data = dat.6)

tab_model(m1, 
          show.se = T, show.std = T, show.stat = T,
          col.order = c("p", "stat", "est", "std.se"))
  sucsong
Predictors p Statistic Estimates standardized std. Error
(Intercept) <0.001 5.67 10.47 0.48
gioi [nu] 0.455 -0.75 -0.34 0.12
tuoi_n2.40-49 tuoi 0.666 0.43 0.24 0.14
tuoi n [3.>50 tuoi] 0.012 2.52 2.15 0.22
dantoc [kinh] 0.483 0.70 0.79 0.29
noio [nguoi quen] 0.702 0.38 0.41 0.28
noio [tro] 0.567 0.57 0.28 0.13
tongiao [phat giao] 0.315 1.01 0.59 0.15
tongiao [thien chua] 0.015 2.46 2.15 0.23
hocvan [2.CD-DH] 0.515 0.65 0.45 0.18
hocvan [3.SDH] 0.347 0.94 0.92 0.25
honnhan [Da ket hon] 0.512 -0.66 -0.42 0.17
honnhan [Ly hon] 0.121 1.55 2.43 0.40
socon [1.con] 0.421 0.81 0.58 0.19
socon [2.con] 0.639 0.47 0.40 0.22
socon [3.con] 0.214 1.24 2.02 0.42
kinhte [2.kha] 0.398 0.85 1.17 0.36
kinhte [3.vua du] 0.606 0.52 0.58 0.29
kinhte [4.kho khan] 0.945 0.07 0.08 0.31
thamnien>1-5nam 0.877 0.16 0.12 0.21
thamnien>10-15nam 0.631 0.48 0.53 0.28
thamnien>15-20 nam 0.880 0.15 0.25 0.43
thamnien [>20 nam] 0.487 -0.70 -1.35 0.50
thamnien>5-10nam 0.277 1.09 0.96 0.23
ban [lam sang] 0.959 -0.05 -0.08 0.38
ban [phong] 0.698 0.39 0.51 0.34
nhiemvu [cham soc] 0.944 -0.07 -0.11 0.39
nhiemvu [chuyenvien] 0.667 -0.43 -0.57 0.34
nhiemvu [dieu tri] 0.852 -0.19 -0.30 0.42
Observations 355
R2 / R2 adjusted 0.106 / 0.029
tab_model(m2, collapse.ci = TRUE, 
          show.std = T, 
          string.p = "P-Value", 
          dv.labels = c("SUC SONG", "M2"),
          string.pred = "Coeffcient",
          string.ci ="Conf.Int(95%)",
          prefix.labels = "varname")
  SUC SONG M2
Coeffcient Estimates std. Beta P-Value
(Intercept) 10.49
(-0.74)
-0.74
(-1.68 – 0.20)
<0.001
gioi [nu] -0.34
(-0.09)
-0.09
(-0.32 – 0.14)
0.431
tuoi_n2.40-49 tuoi -0.07
(-0.02)
-0.02
(-0.30 – 0.26)
0.897
tuoi n [3.>50 tuoi] 1.75
(0.47)
0.47
(0.04 – 0.90)
0.033
dantoc [kinh] 0.73
(0.20)
0.20
(-0.38 – 0.77)
0.498
noio [nguoi quen] 0.43
(0.12)
0.12
(-0.43 – 0.66)
0.679
noio [tro] 0.10
(0.03)
0.03
(-0.22 – 0.28)
0.824
tongiao [phat giao] 0.45
(0.12)
0.12
(-0.18 – 0.42)
0.423
tongiao [thien chua] 1.92
(0.52)
0.52
(0.07 – 0.96)
0.022
hocvan [2.CD-DH] 0.64
(0.17)
0.17
(-0.18 – 0.53)
0.333
hocvan [3.SDH] 1.23
(0.33)
0.33
(-0.17 – 0.83)
0.190
honnhan [Da ket hon] -0.38
(-0.10)
-0.10
(-0.43 – 0.22)
0.534
honnhan [Ly hon] 3.19
(0.86)
0.86
(0.07 – 1.65)
0.034
socon [1.con] 0.55
(0.15)
0.15
(-0.22 – 0.52)
0.428
socon [2.con] 0.54
(0.15)
0.15
(-0.29 – 0.58)
0.509
socon [3.con] 2.15
(0.58)
0.58
(-0.25 – 1.40)
0.168
kinhte [2.kha] 1.33
(0.36)
0.36
(-0.34 – 1.06)
0.316
kinhte [3.vua du] 0.79
(0.21)
0.21
(-0.36 – 0.78)
0.461
kinhte [4.kho khan] 0.54
(0.14)
0.14
(-0.46 – 0.75)
0.637
thamnien>1-5nam 0.27
(0.07)
0.07
(-0.33 – 0.48)
0.718
thamnien>10-15nam 0.56
(0.15)
0.15
(-0.40 – 0.71)
0.591
thamnien>15-20 nam 0.41
(0.11)
0.11
(-0.74 – 0.96)
0.797
thamnien [>20 nam] -0.30
(-0.08)
-0.08
(-1.07 – 0.90)
0.870
thamnien>5-10nam 1.14
(0.31)
0.31
(-0.14 – 0.76)
0.181
ban [lam sang] -0.96
(-0.26)
-0.26
(-1.00 – 0.49)
0.497
ban [phong] 0.41
(0.11)
0.11
(-0.55 – 0.77)
0.742
nhiemvu [cham soc] 0.57
(0.15)
0.15
(-0.61 – 0.92)
0.694
nhiemvu [chuyenvien] -0.53
(-0.14)
-0.14
(-0.81 – 0.53)
0.676
nhiemvu [dieu tri] 0.50
(0.13)
0.13
(-0.68 – 0.95)
0.747
Observations 355
R2 / R2 adjusted 0.113 / 0.037
tab_model(m3, collapse.ci = TRUE)
  sayme
Predictors Estimates p
(Intercept) 7.83
(4.40 – 11.26)
<0.001
gioi [nu] -0.60
(-1.44 – 0.25)
0.164
tuoi_n2.40-49 tuoi 0.21
(-0.82 – 1.23)
0.691
tuoi n [3.>50 tuoi] 2.24
(0.66 – 3.82)
0.006
dantoc [kinh] 0.84
(-1.26 – 2.95)
0.432
noio [nguoi quen] 0.27
(-1.74 – 2.27)
0.793
noio [tro] 0.27
(-0.64 – 1.17)
0.564
tongiao [phat giao] 0.51
(-0.58 – 1.60)
0.358
tongiao [thien chua] 0.83
(-0.79 – 2.46)
0.312
hocvan [2.CD-DH] 0.30
(-0.97 – 1.56)
0.644
hocvan [3.SDH] 1.03
(-0.67 – 2.73)
0.236
honnhan [Da ket hon] -0.32
(-1.53 – 0.88)
0.596
honnhan [Ly hon] 1.98
(-0.90 – 4.87)
0.177
socon [1.con] 0.76
(-0.58 – 2.11)
0.266
socon [2.con] 0.34
(-1.23 – 1.91)
0.671
socon [3.con] 3.32
(0.30 – 6.33)
0.031
kinhte [2.kha] 1.53
(-1.02 – 4.08)
0.238
kinhte [3.vua du] 1.28
(-0.81 – 3.37)
0.229
kinhte [4.kho khan] 0.40
(-1.80 – 2.59)
0.723
thamnien>1-5nam 1.67
(0.19 – 3.15)
0.027
thamnien>10-15nam 1.46
(-0.57 – 3.49)
0.158
thamnien>15-20 nam 0.87
(-2.24 – 3.98)
0.581
thamnien [>20 nam] 0.92
(-2.69 – 4.52)
0.618
thamnien>5-10nam 1.63
(-0.02 – 3.28)
0.053
ban [lam sang] 0.46
(-0.59 – 1.50)
0.393
ban [phong] 0.46
(-0.84 – 1.75)
0.489
Observations 355
R2 / R2 adjusted 0.118 / 0.051
tab_model(m4)
  uwesTong
Predictors Estimates CI p
(Intercept) 28.79 18.84 – 38.75 <0.001
gioi [nu] -1.24 -3.68 – 1.20 0.319
tuoi_n2.40-49 tuoi 0.40 -2.57 – 3.37 0.791
tuoi n [3.>50 tuoi] 6.07 1.48 – 10.65 0.010
dantoc [kinh] 2.38 -3.74 – 8.49 0.445
noio [nguoi quen] 1.20 -4.62 – 7.02 0.685
noio [tro] 0.66 -1.98 – 3.29 0.624
tongiao [phat giao] 1.55 -1.62 – 4.72 0.337
tongiao [thien chua] 4.77 0.07 – 9.48 0.047
hocvan [2.CD-DH] 1.45 -2.23 – 5.12 0.439
hocvan [3.SDH] 3.12 -1.82 – 8.06 0.215
honnhan [Da ket hon] -1.11 -4.60 – 2.38 0.531
honnhan [Ly hon] 7.35 -1.02 – 15.72 0.085
socon [1.con] 1.85 -2.06 – 5.75 0.353
socon [2.con] 1.22 -3.35 – 5.78 0.600
socon [3.con] 7.67 -1.08 – 16.43 0.086
kinhte [2.kha] 3.72 -3.67 – 11.11 0.323
kinhte [3.vua du] 2.51 -3.54 – 8.57 0.415
kinhte [4.kho khan] 0.82 -5.55 – 7.18 0.801
thamnien>1-5nam 2.11 -2.18 – 6.40 0.334
thamnien>10-15nam 2.63 -3.27 – 8.52 0.382
thamnien>15-20 nam 1.38 -7.65 – 10.40 0.764
thamnien [>20 nam] -0.51 -10.98 – 9.95 0.923
thamnien>5-10nam 3.81 -0.98 – 8.60 0.119
ban [lam sang] -0.19 -3.23 – 2.85 0.902
ban [phong] 0.52 -3.25 – 4.28 0.787
Observations 355
R2 / R2 adjusted 0.113 / 0.046
tab_model(m4, show.se = T, show.std = T, show.stat = T)
  uwesTong
Predictors Estimates std. Error std. Beta standardized std. Error CI standardized CI Statistic p
(Intercept) 28.79 5.06 -0.91 0.47 18.84 – 38.75 -1.84 – 0.01 5.69 <0.001
gioi [nu] -1.24 1.24 -0.12 0.12 -3.68 – 1.20 -0.34 – 0.11 -1.00 0.319
tuoi_n2.40-49 tuoi 0.40 1.51 0.04 0.14 -2.57 – 3.37 -0.24 – 0.31 0.27 0.791
tuoi n [3.>50 tuoi] 6.07 2.33 0.57 0.22 1.48 – 10.65 0.14 – 0.99 2.60 0.010
dantoc [kinh] 2.38 3.11 0.22 0.29 -3.74 – 8.49 -0.35 – 0.79 0.76 0.445
noio [nguoi quen] 1.20 2.96 0.11 0.28 -4.62 – 7.02 -0.43 – 0.65 0.41 0.685
noio [tro] 0.66 1.34 0.06 0.12 -1.98 – 3.29 -0.18 – 0.31 0.49 0.624
tongiao [phat giao] 1.55 1.61 0.14 0.15 -1.62 – 4.72 -0.15 – 0.44 0.96 0.337
tongiao [thien chua] 4.77 2.39 0.45 0.22 0.07 – 9.48 0.01 – 0.88 2.00 0.047
hocvan [2.CD-DH] 1.45 1.87 0.14 0.17 -2.23 – 5.12 -0.21 – 0.48 0.78 0.439
hocvan [3.SDH] 3.12 2.51 0.29 0.23 -1.82 – 8.06 -0.17 – 0.75 1.24 0.215
honnhan [Da ket hon] -1.11 1.78 -0.10 0.17 -4.60 – 2.38 -0.43 – 0.22 -0.63 0.531
honnhan [Ly hon] 7.35 4.25 0.69 0.40 -1.02 – 15.72 -0.10 – 1.47 1.73 0.085
socon [1.con] 1.85 1.98 0.17 0.18 -2.06 – 5.75 -0.19 – 0.54 0.93 0.353
socon [2.con] 1.22 2.32 0.11 0.22 -3.35 – 5.78 -0.31 – 0.54 0.52 0.600
socon [3.con] 7.67 4.45 0.72 0.42 -1.08 – 16.43 -0.10 – 1.53 1.72 0.086
kinhte [2.kha] 3.72 3.76 0.35 0.35 -3.67 – 11.11 -0.34 – 1.04 0.99 0.323
kinhte [3.vua du] 2.51 3.08 0.23 0.29 -3.54 – 8.57 -0.33 – 0.80 0.82 0.415
kinhte [4.kho khan] 0.82 3.24 0.08 0.30 -5.55 – 7.18 -0.52 – 0.67 0.25 0.801
thamnien>1-5nam 2.11 2.18 0.20 0.20 -2.18 – 6.40 -0.20 – 0.60 0.97 0.334
thamnien>10-15nam 2.63 3.00 0.24 0.28 -3.27 – 8.52 -0.31 – 0.79 0.88 0.382
thamnien>15-20 nam 1.38 4.59 0.13 0.43 -7.65 – 10.40 -0.71 – 0.97 0.30 0.764
thamnien [>20 nam] -0.51 5.32 -0.05 0.50 -10.98 – 9.95 -1.02 – 0.93 -0.10 0.923
thamnien>5-10nam 3.81 2.43 0.36 0.23 -0.98 – 8.60 -0.09 – 0.80 1.56 0.119
ban [lam sang] -0.19 1.55 -0.02 0.14 -3.23 – 2.85 -0.30 – 0.27 -0.12 0.902
ban [phong] 0.52 1.91 0.05 0.18 -3.25 – 4.28 -0.30 – 0.40 0.27 0.787
Observations 355
R2 / R2 adjusted 0.113 / 0.046
tab_model(m5)
  gjsTong
Predictors Estimates CI p
(Intercept) 35.18 29.77 – 40.59 <0.001
gioi [nu] -1.51 -2.84 – -0.18 0.026
tuoi_n2.40-49 tuoi -0.06 -1.67 – 1.56 0.943
tuoi n [3.>50 tuoi] 1.84 -0.65 – 4.33 0.147
dantoc [kinh] 1.11 -2.21 – 4.44 0.511
noio [nguoi quen] -0.65 -3.81 – 2.51 0.686
noio [tro] -0.14 -1.57 – 1.29 0.850
tongiao [phat giao] 1.64 -0.08 – 3.36 0.062
tongiao [thien chua] -0.46 -3.02 – 2.10 0.724
hocvan [2.CD-DH] 1.22 -0.78 – 3.22 0.231
hocvan [3.SDH] 1.39 -1.29 – 4.08 0.308
honnhan [Da ket hon] -0.88 -2.77 – 1.02 0.364
honnhan [Ly hon] 5.62 1.07 – 10.17 0.016
socon [1.con] 1.75 -0.37 – 3.87 0.106
socon [2.con] 2.46 -0.02 – 4.94 0.052
socon [3.con] 2.16 -2.60 – 6.92 0.372
kinhte [2.kha] 2.76 -1.26 – 6.77 0.178
kinhte [3.vua du] 0.53 -2.76 – 3.83 0.750
kinhte [4.kho khan] -0.15 -3.61 – 3.31 0.931
thamnien>1-5nam -1.11 -3.44 – 1.23 0.351
thamnien>10-15nam 0.42 -2.79 – 3.62 0.797
thamnien>15-20 nam -0.66 -5.56 – 4.24 0.791
thamnien [>20 nam] -1.04 -6.73 – 4.64 0.718
thamnien>5-10nam 0.35 -2.26 – 2.95 0.794
ban [lam sang] 0.37 -1.29 – 2.02 0.662
ban [phong] 1.94 -0.11 – 3.98 0.063
Observations 355
R2 / R2 adjusted 0.165 / 0.102
tab_model(m1, m2, m3,m4,m5, transform = NULL, auto.label = T, string.p = "P-Value")
  sucsong conghien sayme uwesTong gjsTong
Predictors Estimates CI P-Value Estimates CI P-Value Estimates CI P-Value Estimates CI P-Value Estimates CI P-Value
(Intercept) 10.47 6.84 – 14.11 <0.001 10.49 7.01 – 13.96 <0.001 7.83 4.40 – 11.26 <0.001 28.79 18.84 – 38.75 <0.001 35.18 29.77 – 40.59 <0.001
gioi [nu] -0.34 -1.23 – 0.55 0.455 -0.34 -1.20 – 0.51 0.431 -0.60 -1.44 – 0.25 0.164 -1.24 -3.68 – 1.20 0.319 -1.51 -2.84 – -0.18 0.026
tuoi_n2.40-49 tuoi 0.24 -0.84 – 1.32 0.666 -0.07 -1.10 – 0.97 0.897 0.21 -0.82 – 1.23 0.691 0.40 -2.57 – 3.37 0.791 -0.06 -1.67 – 1.56 0.943
tuoi n [3.>50 tuoi] 2.15 0.47 – 3.82 0.012 1.75 0.15 – 3.35 0.033 2.24 0.66 – 3.82 0.006 6.07 1.48 – 10.65 0.010 1.84 -0.65 – 4.33 0.147
dantoc [kinh] 0.79 -1.43 – 3.02 0.483 0.73 -1.39 – 2.86 0.498 0.84 -1.26 – 2.95 0.432 2.38 -3.74 – 8.49 0.445 1.11 -2.21 – 4.44 0.511
noio [nguoi quen] 0.41 -1.71 – 2.53 0.702 0.43 -1.60 – 2.46 0.679 0.27 -1.74 – 2.27 0.793 1.20 -4.62 – 7.02 0.685 -0.65 -3.81 – 2.51 0.686
noio [tro] 0.28 -0.68 – 1.25 0.567 0.10 -0.82 – 1.03 0.824 0.27 -0.64 – 1.17 0.564 0.66 -1.98 – 3.29 0.624 -0.14 -1.57 – 1.29 0.850
tongiao [phat giao] 0.59 -0.56 – 1.75 0.315 0.45 -0.65 – 1.56 0.423 0.51 -0.58 – 1.60 0.358 1.55 -1.62 – 4.72 0.337 1.64 -0.08 – 3.36 0.062
tongiao [thien chua] 2.15 0.43 – 3.87 0.015 1.92 0.27 – 3.57 0.022 0.83 -0.79 – 2.46 0.312 4.77 0.07 – 9.48 0.047 -0.46 -3.02 – 2.10 0.724
hocvan [2.CD-DH] 0.45 -0.91 – 1.82 0.515 0.64 -0.66 – 1.95 0.333 0.30 -0.97 – 1.56 0.644 1.45 -2.23 – 5.12 0.439 1.22 -0.78 – 3.22 0.231
hocvan [3.SDH] 0.92 -1.00 – 2.85 0.347 1.23 -0.61 – 3.08 0.190 1.03 -0.67 – 2.73 0.236 3.12 -1.82 – 8.06 0.215 1.39 -1.29 – 4.08 0.308
honnhan [Da ket hon] -0.42 -1.69 – 0.85 0.512 -0.38 -1.60 – 0.83 0.534 -0.32 -1.53 – 0.88 0.596 -1.11 -4.60 – 2.38 0.531 -0.88 -2.77 – 1.02 0.364
honnhan [Ly hon] 2.43 -0.65 – 5.50 0.121 3.19 0.25 – 6.13 0.034 1.98 -0.90 – 4.87 0.177 7.35 -1.02 – 15.72 0.085 5.62 1.07 – 10.17 0.016
socon [1.con] 0.58 -0.84 – 2.01 0.421 0.55 -0.82 – 1.92 0.428 0.76 -0.58 – 2.11 0.266 1.85 -2.06 – 5.75 0.353 1.75 -0.37 – 3.87 0.106
socon [2.con] 0.40 -1.27 – 2.07 0.639 0.54 -1.06 – 2.14 0.509 0.34 -1.23 – 1.91 0.671 1.22 -3.35 – 5.78 0.600 2.46 -0.02 – 4.94 0.052
socon [3.con] 2.02 -1.18 – 5.22 0.214 2.15 -0.91 – 5.21 0.168 3.32 0.30 – 6.33 0.031 7.67 -1.08 – 16.43 0.086 2.16 -2.60 – 6.92 0.372
kinhte [2.kha] 1.17 -1.55 – 3.90 0.398 1.33 -1.28 – 3.94 0.316 1.53 -1.02 – 4.08 0.238 3.72 -3.67 – 11.11 0.323 2.76 -1.26 – 6.77 0.178
kinhte [3.vua du] 0.58 -1.63 – 2.79 0.606 0.79 -1.32 – 2.91 0.461 1.28 -0.81 – 3.37 0.229 2.51 -3.54 – 8.57 0.415 0.53 -2.76 – 3.83 0.750
kinhte [4.kho khan] 0.08 -2.25 – 2.41 0.945 0.54 -1.70 – 2.77 0.637 0.40 -1.80 – 2.59 0.723 0.82 -5.55 – 7.18 0.801 -0.15 -3.61 – 3.31 0.931
thamnien>1-5nam 0.12 -1.44 – 1.69 0.877 0.27 -1.22 – 1.77 0.718 1.67 0.19 – 3.15 0.027 2.11 -2.18 – 6.40 0.334 -1.11 -3.44 – 1.23 0.351
thamnien>10-15nam 0.53 -1.62 – 2.68 0.631 0.56 -1.49 – 2.62 0.591 1.46 -0.57 – 3.49 0.158 2.63 -3.27 – 8.52 0.382 0.42 -2.79 – 3.62 0.797
thamnien>15-20 nam 0.25 -3.05 – 3.56 0.880 0.41 -2.75 – 3.58 0.797 0.87 -2.24 – 3.98 0.581 1.38 -7.65 – 10.40 0.764 -0.66 -5.56 – 4.24 0.791
thamnien [>20 nam] -1.35 -5.18 – 2.47 0.487 -0.30 -3.97 – 3.36 0.870 0.92 -2.69 – 4.52 0.618 -0.51 -10.98 – 9.95 0.923 -1.04 -6.73 – 4.64 0.718
thamnien>5-10nam 0.96 -0.78 – 2.71 0.277 1.14 -0.53 – 2.81 0.181 1.63 -0.02 – 3.28 0.053 3.81 -0.98 – 8.60 0.119 0.35 -2.26 – 2.95 0.794
ban [lam sang] -0.08 -2.96 – 2.81 0.959 -0.96 -3.72 – 1.81 0.497 0.46 -0.59 – 1.50 0.393 -0.19 -3.23 – 2.85 0.902 0.37 -1.29 – 2.02 0.662
ban [phong] 0.51 -2.06 – 3.08 0.698 0.41 -2.05 – 2.87 0.742 0.46 -0.84 – 1.75 0.489 0.52 -3.25 – 4.28 0.787 1.94 -0.11 – 3.98 0.063
nhiemvu [cham soc] -0.11 -3.09 – 2.88 0.944 0.57 -2.28 – 3.43 0.694
nhiemvu [chuyenvien] -0.57 -3.17 – 2.03 0.667 -0.53 -3.02 – 1.96 0.676
nhiemvu [dieu tri] -0.30 -3.47 – 2.87 0.852 0.50 -2.53 – 3.53 0.747
Observations 355 355 355 355 355
R2 / R2 adjusted 0.106 / 0.029 0.113 / 0.037 0.118 / 0.051 0.113 / 0.046 0.165 / 0.102
tab_model(m2, show.se =T, show.std = T, show.stat = T, string.p = "P-Value")
  conghien
Predictors Estimates std. Error std. Beta standardized std. Error CI standardized CI Statistic P-Value
(Intercept) 10.49 1.77 -0.74 0.48 7.01 – 13.96 -1.68 – 0.20 5.93 <0.001
gioi [nu] -0.34 0.43 -0.09 0.12 -1.20 – 0.51 -0.32 – 0.14 -0.79 0.431
tuoi_n2.40-49 tuoi -0.07 0.53 -0.02 0.14 -1.10 – 0.97 -0.30 – 0.26 -0.13 0.897
tuoi n [3.>50 tuoi] 1.75 0.81 0.47 0.22 0.15 – 3.35 0.04 – 0.90 2.15 0.033
dantoc [kinh] 0.73 1.08 0.20 0.29 -1.39 – 2.86 -0.38 – 0.77 0.68 0.498
noio [nguoi quen] 0.43 1.03 0.12 0.28 -1.60 – 2.46 -0.43 – 0.66 0.41 0.679
noio [tro] 0.10 0.47 0.03 0.13 -0.82 – 1.03 -0.22 – 0.28 0.22 0.824
tongiao [phat giao] 0.45 0.56 0.12 0.15 -0.65 – 1.56 -0.18 – 0.42 0.80 0.423
tongiao [thien chua] 1.92 0.84 0.52 0.23 0.27 – 3.57 0.07 – 0.96 2.30 0.022
hocvan [2.CD-DH] 0.64 0.66 0.17 0.18 -0.66 – 1.95 -0.18 – 0.53 0.97 0.333
hocvan [3.SDH] 1.23 0.94 0.33 0.25 -0.61 – 3.08 -0.17 – 0.83 1.31 0.190
honnhan [Da ket hon] -0.38 0.62 -0.10 0.17 -1.60 – 0.83 -0.43 – 0.22 -0.62 0.534
honnhan [Ly hon] 3.19 1.49 0.86 0.40 0.25 – 6.13 0.07 – 1.65 2.13 0.034
socon [1.con] 0.55 0.69 0.15 0.19 -0.82 – 1.92 -0.22 – 0.52 0.79 0.428
socon [2.con] 0.54 0.81 0.15 0.22 -1.06 – 2.14 -0.29 – 0.58 0.66 0.509
socon [3.con] 2.15 1.56 0.58 0.42 -0.91 – 5.21 -0.25 – 1.40 1.38 0.168
kinhte [2.kha] 1.33 1.33 0.36 0.36 -1.28 – 3.94 -0.34 – 1.06 1.00 0.316
kinhte [3.vua du] 0.79 1.08 0.21 0.29 -1.32 – 2.91 -0.36 – 0.78 0.74 0.461
kinhte [4.kho khan] 0.54 1.13 0.14 0.31 -1.70 – 2.77 -0.46 – 0.75 0.47 0.637
thamnien>1-5nam 0.27 0.76 0.07 0.20 -1.22 – 1.77 -0.33 – 0.48 0.36 0.718
thamnien>10-15nam 0.56 1.05 0.15 0.28 -1.49 – 2.62 -0.40 – 0.71 0.54 0.591
thamnien>15-20 nam 0.41 1.61 0.11 0.43 -2.75 – 3.58 -0.74 – 0.96 0.26 0.797
thamnien [>20 nam] -0.30 1.86 -0.08 0.50 -3.97 – 3.36 -1.07 – 0.90 -0.16 0.870
thamnien>5-10nam 1.14 0.85 0.31 0.23 -0.53 – 2.81 -0.14 – 0.76 1.34 0.181
ban [lam sang] -0.96 1.41 -0.26 0.38 -3.72 – 1.81 -1.00 – 0.49 -0.68 0.497
ban [phong] 0.41 1.25 0.11 0.34 -2.05 – 2.87 -0.55 – 0.77 0.33 0.742
nhiemvu [cham soc] 0.57 1.45 0.15 0.39 -2.28 – 3.43 -0.61 – 0.92 0.39 0.694
nhiemvu [chuyenvien] -0.53 1.27 -0.14 0.34 -3.02 – 1.96 -0.81 – 0.53 -0.42 0.676
nhiemvu [dieu tri] 0.50 1.54 0.13 0.42 -2.53 – 3.53 -0.68 – 0.95 0.32 0.747
Observations 355
R2 / R2 adjusted 0.113 / 0.037
library(tables)
 tabular(gioi + tuoi + tuoi_n + dantoc + noio + tongiao + hocvan + honnhan + socon + kinhte + thamnien + ban + nhiemvu)~ mucdoUWES_2*(n=1 + Percent("row"))
## tabular(gioi + tuoi + tuoi_n + dantoc + noio + tongiao + hocvan + 
##     honnhan + socon + kinhte + thamnien + ban + nhiemvu) ~ mucdoUWES_2 * 
##     (n = 1 + Percent("row"))
# toHTML(t.1,format="html", digits = 3) 

hết