Setup

First we load the MHAS 2018 sample, and restrict the sample to people who have diabetes, and older than 50 years old.

Descriptives

We are going to observe different variables split by urban or rural. Urban or rural is defined as 1 for all those people in communities with a population of 100,000 or more.

Proportion of urban population:

Urban % n
0.6142516 2512
locality females n freq
0 0 611 0.3959819
0 1 932 0.6040181
1 0 226 0.3843537
1 1 362 0.6156463
2 0 123 0.3228346
2 1 258 0.6771654

Proportion Female

urban Female % SD n
0 0.6398349 0.4802960 969
1 0.6040181 0.4892191 1543

Age

urban Mean Age SD n
0 69.3612 8.268829 969
1 69.8464 8.355377 1543

Marital Status

urban married n freq
0 0 376 0.3884298
0 1 592 0.6115702
1 0 649 0.4228013
1 1 886 0.5771987

Employment Status

urban i16_18 n freq
0 1.Is working 222 0.2310094
0 3.Doesn’t work 739 0.7689906
1 1.Is working 373 0.2445902
1 3.Doesn’t work 1152 0.7554098

Education (in years)

urban Mean Years SD n
0 4.399793 3.803373 968
1 6.463559 4.542740 1523

Depression

urban c49_1_18 n freq
0 1.Yes 363 0.4186851
0 2.No 504 0.5813149
1 1.Yes 516 0.3626142
1 2.No 907 0.6373858

Smoking

urban c51_18 n freq
0 1.Yes 297 0.3068182
0 2.No 671 0.6931818
1 1.Yes 628 0.4069994
1 2.No 915 0.5930006

Medical Visit Costs

urban Mean Costs SD n
0 5527.482 16564.68 247
1 5416.006 12922.20 337

Number of Medical Visits

urban Mean Visits SD n
0 8.669763 9.805564 969
1 9.005844 10.524977 1540

Medication Costs

urban Mean Medication Costs SD n
0 2098.418 9634.605 505
1 2883.854 29900.102 753

Number of Overnight Hospital Stays

urban Mean Overnight Stays SD n
0 7.475728 15.73087 206
1 8.882006 16.19055 339

We can run a few regressions to explore different relationships between the data and the variables.

Dependent variable:
log(med_cost) log(visit_cost) log(med_cost) log(visit_cost)
(1) (2) (3) (4)
urban 0.071 -0.491 0.075 -0.479
(0.359) (0.334) (0.360) (0.334)
BMI -0.006 -0.015
(0.023) (0.022)
as.factor(female)1 -0.211 0.361 -0.200 0.391
(0.394) (0.366) (0.397) (0.368)
as.factor(IMSS)1 -1.848*** -2.491*** -1.850*** -2.495***
(0.397) (0.369) (0.397) (0.369)
as.factor(SP)1 0.585 -0.194 0.584 -0.195
(0.488) (0.453) (0.488) (0.453)
age 0.038* 0.067*** 0.038 0.066***
(0.023) (0.021) (0.023) (0.021)
as.factor(married)1 -0.388 0.593* -0.390 0.588*
(0.349) (0.324) (0.349) (0.324)
as.factor(employed)1 0.293 1.478*** 0.296 1.485***
(0.409) (0.379) (0.409) (0.380)
educ 0.128*** 0.095** 0.128*** 0.093**
(0.044) (0.041) (0.044) (0.041)
as.factor(depression)1 0.633* -0.071 0.633* -0.073
(0.336) (0.312) (0.336) (0.312)
as.factor(smoker)1 -1.064*** -0.727** -1.067*** -0.735**
(0.359) (0.333) (0.359) (0.333)
Constant -2.378 -7.240*** -2.178 -6.732***
(1.940) (1.800) (2.088) (1.938)
Observations 1,669 1,669 1,669 1,669
R2 0.039 0.057 0.039 0.058
Adjusted R2 0.033 0.052 0.033 0.051
Residual Std. Error 6.537 (df = 1658) 6.067 (df = 1658) 6.539 (df = 1657) 6.068 (df = 1657)
F Statistic 6.732*** (df = 10; 1658) 10.085*** (df = 10; 1658) 6.123*** (df = 11; 1657) 9.211*** (df = 11; 1657)
Note: p<0.1; p<0.05; p<0.01

Add Suburban as a Locality

Now let’s observe the models with locality rather than urban. With regards to locality:

Dependent variable:
log(med_cost) log(visit_cost) log(med_cost) log(visit_cost)
(1) (2) (3) (4)
as.factor(locality)1 0.019 0.624* 0.015 0.613*
(0.396) (0.368) (0.397) (0.369)
as.factor(locality)2 1.348*** 1.702*** 1.346*** 1.694***
(0.515) (0.479) (0.515) (0.479)
BMI -0.005 -0.014
(0.023) (0.022)
as.factor(female)1 -0.244 0.336 -0.235 0.363
(0.397) (0.369) (0.400) (0.372)
as.factor(public_coverage)1 -1.445*** -1.951*** -1.446*** -1.954***
(0.420) (0.391) (0.420) (0.391)
age 0.026 0.056*** 0.026 0.056***
(0.023) (0.021) (0.023) (0.021)
as.factor(married)1 -0.593* 0.410 -0.595* 0.405
(0.351) (0.326) (0.351) (0.326)
as.factor(employed)1 0.350 1.539*** 0.352 1.545***
(0.411) (0.383) (0.412) (0.383)
educ 0.108** 0.079* 0.108** 0.078*
(0.044) (0.041) (0.044) (0.041)
as.factor(depression)1 0.653* -0.067 0.652* -0.069
(0.339) (0.315) (0.339) (0.315)
as.factor(smoker)1 -1.158*** -0.825** -1.161*** -0.832**
(0.361) (0.336) (0.361) (0.336)
Constant -1.247 -6.957*** -1.088 -6.492***
(1.964) (1.826) (2.119) (1.970)
Observations 1,669 1,669 1,669 1,669
R2 0.026 0.040 0.026 0.041
Adjusted R2 0.020 0.035 0.020 0.034
Residual Std. Error 6.581 (df = 1658) 6.121 (df = 1658) 6.583 (df = 1657) 6.122 (df = 1657)
F Statistic 4.418*** (df = 10; 1658) 6.996*** (df = 10; 1658) 4.018*** (df = 11; 1657) 6.393*** (df = 11; 1657)
Note: p<0.1; p<0.05; p<0.01

Add Interactions of Gender

Dependent variable:
log(med_cost) log(visit_cost) log(med_cost) log(visit_cost)
(1) (2) (3) (4)
as.factor(locality)1 -0.307 0.401 -0.309 0.395
(0.641) (0.597) (0.642) (0.597)
as.factor(locality)2 2.296*** 2.009** 2.299*** 2.016**
(0.853) (0.794) (0.853) (0.794)
BMI -0.006 -0.014
(0.024) (0.022)
as.factor(female)1 -0.201 0.306 -0.187 0.339
(0.463) (0.430) (0.466) (0.434)
as.factor(public_coverage)1 -1.441*** -1.951*** -1.442*** -1.954***
(0.420) (0.391) (0.420) (0.391)
age 0.024 0.056*** 0.024 0.055**
(0.023) (0.021) (0.023) (0.022)
as.factor(married)1 -0.586* 0.410 -0.588* 0.406
(0.351) (0.326) (0.351) (0.326)
as.factor(employed)1 0.319 1.528*** 0.322 1.534***
(0.412) (0.383) (0.412) (0.383)
educ 0.108** 0.079* 0.108** 0.078*
(0.044) (0.041) (0.044) (0.041)
as.factor(depression)1 0.632* -0.076 0.632* -0.078
(0.339) (0.315) (0.339) (0.315)
as.factor(smoker)1 -1.168*** -0.827** -1.171*** -0.835**
(0.361) (0.336) (0.361) (0.336)
as.factor(locality)1:as.factor(female)1 0.512 0.354 0.508 0.345
(0.806) (0.750) (0.806) (0.750)
as.factor(locality)2:as.factor(female)1 -1.449 -0.466 -1.458 -0.488
(1.052) (0.979) (1.053) (0.979)
Constant -1.109 -6.888*** -0.918 -6.415***
(1.966) (1.830) (2.121) (1.974)
Observations 1,669 1,669 1,669 1,669
R2 0.028 0.041 0.028 0.041
Adjusted R2 0.021 0.034 0.020 0.034
Residual Std. Error 6.580 (df = 1656) 6.123 (df = 1656) 6.582 (df = 1655) 6.124 (df = 1655)
F Statistic 3.915*** (df = 12; 1656) 5.872*** (df = 12; 1656) 3.616*** (df = 13; 1655) 5.450*** (df = 13; 1655)
Note: p<0.1; p<0.05; p<0.01