Public Health Statistics Workflow

Crude comparisons, age-adjusted sensitivity analysis, and exploratory interaction checks

1 Overview

This Quarto report is the stakeholder-facing presentation layer for the project. The Jupyter notebook remains the main analysis workspace and continues to produce the summary table, forest plots, and exploratory figures. This report reuses those generated outputs to present the analysis in a cleaner, narrative format.

The workflow is intentionally reproducible and local: generated outputs are written to outputs/, while raw data remain outside Git. The report summarizes crude comparisons, age-adjusted sensitivity analyses, and an exploratory sex-by-age interaction check without changing the underlying calculations.

For complete environment and reproducibility details, see REPRODUCIBILITY.md.

2 Analytic Objective

The aim of this analysis is to describe how a small set of public-health measures differs between Male and Female participants, then check whether those differences persist after age-group adjustment. A secondary goal is to explore whether sex differences vary across age groups.

This is an observational descriptive workflow. It is designed to summarize patterns, not to support causal claims.

3 Methods

3.1 Sample and variables

The analytic dataset contains 845 participants, with 437 Male and 408 Female participants. Age is grouped into four broad categories spanning the 40s through the 70s. The analysis covers continuous cardiometabolic measures, dietary variables, urinary sodium excretion, and binary cutoff indicators derived from assignment-specific thresholds.

3.2 Crude descriptive analysis

The main summary table reports descriptive statistics by sex and overall. Continuous variables are summarized with means, standard deviations, medians, and interquartile ranges. Binary and categorical variables are summarized with percentages. Mann-Whitney U tests are used for crude continuous comparisons, and chi-square tests are used for crude categorical and binary comparisons.

These crude results are unadjusted. They are useful for describing the data, but they do not account for age-group composition.

3.3 Exploratory visualizations

The crude visualizations use simple matplotlib figures to show distributions by sex, age-group composition, and cutoff prevalence. The goal is to make patterns easier to see without adding unnecessary graphical complexity.

3.4 Age-adjusted sensitivity analysis

The age-adjusted models estimate Female vs Male contrasts after adjusting for categorical age group only. Continuous outcomes are modeled with linear regression, and binary cutoff outcomes are modeled with logistic regression. The resulting forest plots show standardized adjusted mean differences for continuous outcomes and adjusted odds ratios for binary outcomes.

These models are sensitivity analyses. They help assess whether the crude comparisons are materially changed by broad age structure, but they do not make the analysis causal.

3.5 Exploratory interaction analysis

The sex-by-age interaction model evaluates whether Female vs Male differences appear to vary across age groups. This is an exploratory subgroup-heterogeneity check, not a primary inferential endpoint. Figure 7 provides the main visual summary of that pattern.

4 Descriptive Summary

The summary table gives the baseline descriptive picture of the sample. In broad terms, the dataset is balanced enough by sex to support a direct comparison, and the age distribution is spread across the four age bands rather than concentrated in a single group.

The continuous measures show meaningful within-group variability, which is why the median and interquartile range are reported alongside the mean and standard deviation. The binary cutoff indicators help translate the same data into public-health-oriented thresholds that are easier to compare across outcomes.

The key interpretive point is that the summary table is descriptive. It is designed to orient the reader before moving into the crude figures and the adjusted analyses that follow.

5 Crude Visualizations

Figure 1. Age-Group Distribution by Sex

Grouped bar chart of age-group distribution by sex.

Figure 1 shows the age composition separately for Male and Female participants. It provides context for the later age-adjusted sensitivity analysis because crude sex comparisons may partly reflect age-group composition if the two groups have different age distributions.

Figure 2. BMI by Sex

Boxplot of BMI by sex.

BMI distributions overlap substantially, which suggests that the crude sex contrast is modest relative to the within-group spread. The p-value in the notebook is only a reference for the unadjusted comparison; the figure itself is more informative about magnitude and overlap than about practical importance.

Figure 3. Blood Glucose by Sex

Boxplot of blood glucose by sex.

Blood glucose also shows overlap between groups, with the boxplots emphasizing the spread and central tendency rather than a single significance threshold. This is a descriptive comparison, so the more useful question is whether the distributions are meaningfully separated rather than whether a p-value crosses an arbitrary cutoff.

Figure 4. Prevalence Above Cutoff Values by Sex

Horizontal grouped bar chart of cutoff prevalence by sex.

This figure is the clearest crude summary of the threshold outcomes because it places all binary indicators on the same percentage scale. It complements the continuous boxplots by showing how the same measures behave when translated into public-health cutoffs. The error bars are approximate and should be read as uncertainty bands rather than as formal hypothesis tests.

6 Age-Adjusted Sensitivity Analysis

The crude figures are informative, but they do not account for broad age-group differences. The next step is to adjust the sex comparisons for categorical age group only and check whether the main patterns persist.

6.1 Forest Plots

Figure 5. Age-Adjusted Standardized Female vs Male Mean Differences

Forest plot of age-adjusted standardized Female vs Male mean differences.

Figure 5 shows standardized adjusted mean differences for the continuous outcomes, sorted by the absolute size of the adjusted Female vs Male contrast. The outcomes are standardized before modeling because their original units and ranges differ, so the estimates are interpreted in standard-deviation units. This makes the cross-outcome visual comparison more meaningful than plotting BMI, blood pressure, glucose, and urinary sodium on one raw-unit axis. Confidence intervals and p-values describe model-based uncertainty, but p-values should not be read as practical importance by themselves.

Figure 6. Age-Adjusted Odds Ratios

Forest plot of age-adjusted odds ratios.

Figure 6 translates the same sex comparison into a prevalence-oriented form for the binary outcomes. Odds ratios are useful here because they align directly with the cutoff definitions and make it easier to see which public-health thresholds show persistence versus attenuation after age adjustment. As with Figure 5, uncertainty matters: confidence intervals describe how stable the adjusted contrast appears, not whether the effect is practically large.

7 Exploratory Sex-by-Age Interaction Analysis

The interaction model asks a narrower exploratory question: do the Female vs Male contrasts look similar across age groups, or do they vary by age stratum? This is useful for subgroup-heterogeneity assessment, but it should not be overinterpreted.

Figure 7. Exploratory Sex-by-Age Interaction

Interaction line plots for continuous outcomes.

This figure is the main interaction visualization because it summarizes how the continuous outcomes behave across both sex and age groups in one place. BMI shows mostly parallel Male and Female lines, and triglycerides remain higher among Male participants across all age groups, although the gap narrows with age. Systolic blood pressure shows the clearest visual convergence and crossing by age group, urinary sodium remains higher among Male participants with a wider gap in the oldest group, and blood glucose lines overlap and cross without a stable sex separation. Because subgroup estimates can be unstable, these patterns should be treated as screening signals rather than definitive interaction results.

8 Results

The overall picture is consistent with a descriptive public-health report: the crude table and figures describe the observed sex differences, the age-adjusted models show which contrasts remain after accounting for age-group composition, and the interaction figure checks whether the sex contrast appears consistent across age strata.

After age-group adjustment, the clearest continuous Female vs Male contrasts are lower triglycerides and lower urinary sodium excretion among Female participants. BMI and systolic blood pressure also remain lower for Female participants after age adjustment, but the adjusted differences are smaller in scale than the triglyceride and urinary sodium contrasts. Blood glucose does not show a clear adjusted Female vs Male difference in the linear model.

The age-adjusted binary cutoff models show a similar pattern for several threshold outcomes: Female participants have lower adjusted odds of BMI at or above 25, waist circumference above cutoff, systolic blood pressure at or above 130 mmHg, triglycerides at or above 150 mg/dL, and urinary sodium at or above 4000 mg/day. In contrast, the adjusted cutoff models for blood glucose, vegetable intake, and fruit intake are less clearly separated by sex. The interaction analysis is more tentative: its value is in highlighting potential age-specific patterns, not in producing a standalone conclusion.

9 Discussion

This analysis is best read as a descriptive public-health summary rather than a causal model. The crude comparisons are useful for orientation, but they can be influenced by age-group composition. The age-adjusted models address that specific limitation by estimating sex contrasts after controlling for categorical age group only.

The most consistent findings point to sex-associated differences in measures connected to body weight, blood pressure, lipids, and urinary sodium. The adjusted continuous models show lower Female values for BMI, systolic blood pressure, triglycerides, and urinary sodium excretion, while the adjusted cutoff models show lower Female odds of crossing the corresponding BMI, waist circumference, systolic blood pressure, triglyceride, and sodium thresholds. These patterns are relevant to public-health interpretation because they summarize body weight, blood pressure, glucose regulation, dietary intake, and urinary sodium indicators on both measurement and threshold scales. They remain descriptive associations and do not identify why the groups differ.

Figure 7 adds a cautious subgroup-pattern check. BMI shows broadly similar, mostly parallel Male and Female age trends, with Male means higher across age groups. Triglycerides also remain higher among Male participants across age groups, though the gap visually narrows with age. Systolic blood pressure shows more age-related convergence and crossing, with Female means lower in the 40s and 50s but similar to or higher than Male means in older groups. Urinary sodium excretion remains higher among Male participants, with the visual gap widening in the 70s. Blood glucose lines overlap and cross, which is consistent with the lack of a clear overall adjusted sex contrast. These visual patterns are exploratory; they should be used to generate questions about age-specific heterogeneity rather than to claim confirmed interactions.

10 Limitations

  • Age is the only adjustment variable currently included in the sensitivity analysis.
  • Small subgroup counts can make some regression estimates unstable, especially in logistic models.
  • The workflow is educational and exploratory rather than a full analytic plan for causal inference.
  • The analysis depends on the local data file and the assignment-specific cutoff definitions used to derive binary indicators.

11 Future Directions

  • Multivariable regression with additional covariates.
  • Interaction analyses with more formal subgroup comparisons.
  • Automated Quarto reporting directly from reusable modules.
  • Expanded plotting and statistics helpers under src/.
  • Adaptation to other clinical or epidemiologic datasets with documented variable definitions.