WorksComputer Science
Inferring Factor Importance with Explainable AI Model for Macrophage Immune Cell Polarization
Abstract
Macrophages are highly plastic immune cells that dynamically shift between pro- and anti-inflammatory phenotypes in response to cytokines, transcriptional regulators, metabolic cues, and local microenvironment. Yet macrophage polarization is governed by nonlinear regulatory networks that are difficult to study experimentally. Here, we integrate mechanistic simulation, surrogate neural networks, and explainable machine learning to identify key regulatory drivers of polarization. We generated simulation data with a COPASI-based macrophage polarization model and used them to train an LSTM surrogate capable of reconstructing temporal macrophage marker dynamics across diverse macrophage activation states. SHAP, Individual Conditional Expectation, and Partial Dependence Plot analyses quantified feature importance, identified nonlinear response regimes, and characterized higher-order interactions among cytokines, transcription factors, and polarization markers. The model identified oxygen availability and IL10 as dominant anti-inflammatory regulators, consistently promoting M2-associated outputs such as ARG1 and VEGF. Conversely, IFN-γ, TNFα, IL12, iNOS, CXCL9, and mCXCL10 reinforced M1-associated inflammatory programs. STAT1-centered analyses identified iNOS, TNFα, and mCXCL10 levels as strong contributors to STAT1 outcomes, consistent with amplification of the IFN- γ/JAK/STAT1 inflammatory axis. VEGF negatively contributed to predicted STAT1 output, suggesting antagonism between M2 markers and M1 activation. SHAP, ICE, and PDP analyses also showed that STAT1 regulation is nonlinear and threshold-like: pro-inflammatory signals must accumulate before STAT1 rises sharply. Together, it demonstrates that the LSTM explainability framework can identify polarization drivers, uncover nonlinear regulatory thresholds, and prioritize pathways for experimental validation.
Introduction
Computational Immune Response Modeling
Macrophage Biology
Macrophages are central regulators of immune decision-making across infection, bone regeneration, tissue injury, cancer, and biomaterial implantation. Rather than functioning as static cell types, macrophages continuously interpret biochemical, mechanical, metabolic, and cellular signals from their local microenvironment to coordinate inflammation, repair, angiogenesis, matrix remodeling, and immune suppression. This context-dependent plasticity makes macrophages both powerful mediators of immune defense. As a result, macrophage phenotype switching has emerged as a critical target for precision medicine, where patient- or disease-specific models may help predict immune trajectories, identify dominant regulatory mechanisms, and guide therapeutic interventions that restore appropriate immune balance.
Macrophages capable of adopting distinct polarization states, primarily named M1 (pro-inflammatory) and M2 (anti-inflammatory). This dynamic behavior is simplified into two polarized states: M1 macrophages drive inflammatory responses critical for pathogen elimination and tissue defense, while M2 macrophages support tissue repair, resolution of inflammation, and immune regulation [1, 2, 3].
Previous Computational Models
A deeper understanding of the mechanisms governing macrophage polarization is therefore essential for developing targeted therapies and biomedical interventions for diseases characterized by immune dysfunction, such as chronic inflammatory conditions, autoimmune disorders, cancer, and implant rejection. Computational modeling offers a powerful approach for unraveling the complex signaling networks that regulate macrophage polarization. The comprehensive model developed by Zhao et al. [8] integrates multiple pathways, including the IFN-, IL-4, and hypoxia signaling cascades, to simulate macrophage behavior under various conditions.
The complexity of macrophage polarization is increasingly appreciated through computational and systems biology approaches. For instance, Zhao et al. [8] demonstrated that modeling of immune networks can reveal emergent behavior in cytokine regulation and macrophage phenotype switching. Model sensitivity analyses can reveal key molecular nodes and interactions as apt targets for potential therapeutic interventions for the pathophysiology of arterial disease and cancers. Further emphasizing the tumor microenvironment context, Leon et al. [7] used network-based methods to decode the interdependency between macrophage behavior and external environmental signals, reinforcing the idea that external cues profoundly modulate polarization states. Studies such as Zhang et al. [10] underscore the utility of dynamic simulations and machine learning models in mapping immune phenotypes and identifying potential therapeutic leverage points across various cancers. Wang et al. [11] developed a quantitative systems pharmacology model that incorporates tumor-associated macrophage (TAM) dynamics to predict immunotherapy outcomes in triple-negative breast cancer. By integrating TAM polarization, cytokine profiles, and digital pathology data, their model captures the immunosuppressive impact of M2 macrophages and supports macrophage-targeted therapeutic strategies. Also studying TAMs, Cess et al. [12] model the TAM/Tumor Cell/T-Cell crosstalk to determine how the immune response changes due to three macrophage-based immunotherapeutic strategies: macrophage depletion, recruitment inhibition, and macrophage reeducation; concluding that reeducation is the best strategy, while TAM recruitment and tumor proliferation play an important role. Torres et al. [13] developed and fit a mathematical model of immune-cell influx during mouse peritonitis, including simplified macrophage polarization, then evaluated model robustness using identifiability and sensitivity analyses. The model reproduced expected inflammatory timing and identified apoptotic neutrophils as a major driver of the inflammatory response. Simulated interventions suggest the model can be used to test macrophage-targeted therapies before experimental validation. Guo et al. [14] represents an important convergence of single-cell imaging, and mathematical modeling toward precision medicine. By combining live-cell measurements of NFB dynamics with simulations that extend beyond experimentally accessible conditions, the work shows how heterogeneous macrophage responses can be integrated at both the population and single-cell levels. Zerrouk et al. [15] offer a study which highlights the use of mechanistic models toward developing new therapeutic targets. For modeling the M1/M2 macrophage ratio in the context of rheumatoid arthritis, this study employs knockout experiments to identify NFB, JAK1/JAK2 and ERK1/Notch1 as targets for suppressing pro-inflammatory macrophages, and GSK3B as a promoter for anti-inflammatory macrophages. For responding to foreign body penetration, Anderson et al. [4] conclude that persistent M1 polarization can drive chronic inflammation and granulation or fibrotic encapsulation, while M2 polarization is associated with tissue remodeling, wound healing, and improved integration of biomaterials [4].
Taken together, this collection of studies highlight macrophage polarization as a broadly applicable modeling target across inflammatory disease, cancer, and immune-mediated tissue remodeling. The convergence of mechanistic mathematical modeling, systems pharmacology, machine learning, single-cell imaging, and dynamic signaling analysis provides an increasingly rich framework for understanding macrophage behavior across biological scales.
Integrating dynamic macrophage models for the development of disease-specific and patient-informed pharmacological models offers a promising strategy for identifying therapeutic leverage points, testing interventions in silico, and ultimately designing precision immunomodulatory strategies tailored to specific environments.
Explainability
Surrogate Modeling
The polarization process is regulated by a large network of interacting genes, cytokines, transcription factors, and microenvironmental signals. Because these components jointly determine whether macrophages adopt pro-inflammatory M1-like, anti-inflammatory M2-like, or intermediate phenotypes, it is essential to quantify their relative importance in maintaining polarization balance and driving phenotype transitions.
To address this challenge, a relative gene-importance modeling study was conducted using a mechanistic computational model of macrophage polarization. Simulation data were generated in COPASI (COmplex PAthway SImulator) [18] and used to train surrogate machine learning models. COPASI is a widely adopted platform for simulating biochemical reaction networks, enabling time-dependent molecular behavior to be modeled through reaction rate equations and concentration-based dynamics.
This surrogate modeling strategy is particularly useful because experimental macrophage studies are constrained by the number of conditions that can be evaluated in vivo or in vitro. In biological experiments, systematically varying many cytokines, transcription factors, pathway activities, and microenvironmental cues across multiple doses and time points is often infeasible due to cost, sample availability, biological variability, and ethical limitations. By contrast, computational simulation allows the model to explore an experimentally impractical number of pathological and therapeutic states, including combinations of perturbations that would be difficult or impossible to generate directly in the laboratory.
In this study, COPASI was used to simulate macrophage polarization across diverse biological conditions relevant to the IFN-, IL-4, and hypoxia signaling pathways. These simulations included variation in cytokine levels, transcription factor activity, and microenvironmental stimuli, producing time-series data for molecular species involved in M1 and M2 polarization. The generated datasets captured balanced polarization states as well as perturbed, skewed, and disease-relevant phenotypes. Surrogate machine learning models trained on these simulations can then rapidly approximate the behavior of the underlying macrophage model, enabling systematic gene-level perturbation studies and feature-importance analyses across a much larger state space than would be experimentally accessible. In this way, surrogate modeling complements experimentation by using mechanistic simulations to identify candidate regulatory drivers, prioritize genes or pathways for validation, and generate hypotheses about macrophage behavior under complex pathological conditions. Full model details, summarized in Table 1, are provided by Zhao et al. [8].
| Model Component | Quantity | Description | Parameterization |
| Reactions (fluxes) | 140 | IL-4, IFN-, hypoxia, feedback loops | Fitted or estimated from literature |
| Unique species | 34 | Core molecules (cytokines, TFs, enzymes, mRNAs) | 31 species calibrated to literature data |
| Model nodes | 109 | Proteins, RNAs, complexes, derived from unique species | Initial copy numbers in molecules per cell (1 pL) |
| Parameters | 141 | Rate constants, affinities, degradation rates | Combination of fitted + published data |
| Calibration datasets | Time-course or steady-state measurements | IFN-, IL-4, hypoxia modules | |
| Pathways covered | 3 major modules | IFN- signaling, IL-4 signaling, hypoxia response | Includes crosstalk (e.g., STAT1/STAT6, HIF) |
Table 1. Summary of model complexity integrating reactions, species, and calibration data.
SHAP Feature Attribution
Advancements in interpretable machine learning, such as laid out in Lundberg et al. [16], provide tools like the SHapley Additive exPlanations (SHAP) to dissect feature contributions in black-box models, which are increasingly applied to biological network analysis. The integration of these methods with simulation frameworks allows for mechanistic interpretation of gene contributions, which can be validated against known markers and experimental perturbations.
ICE and Partial Dependence Analysis
Complementary to SHAP, feature effect methods such as Individual Conditional Expectation (ICE) and Partial Dependence Plots (PDP) [17] provide insight into how model predictions respond to variations in specific inputs. ICE curves capture sample-specific prediction trajectories by varying a single feature while holding others constant, thereby revealing heterogeneity and interaction effects that are often obscured in global summaries. PDPs summarize the average influence of a feature across the data distribution. Together, these approaches enable identification of nonlinear behaviors, threshold effects, and regime-dependent dynamics in gene regulatory networks. When applied to temporal or mechanistic models, ICE and PDP analyses further allow interpretation of how perturbations propagate through the system, offering a functional perspective that complements the attribution-based insights provided by SHAP.
Through the integration of computational simulations, explainable machine learning, and data-driven modeling, this study offers insights into the relative importance of regulatory mechanisms for macrophage polarization and their therapeutic implications.
Inferring Factor Importance
Biomaterial Integration Model Specificity
Following implantation, macrophages are among the first immune cells to interact with the foreign material surface, where their phenotype influences whether the local environment progresses toward constructive tissue integration, chronic inflammation, fibrotic encapsulation, or biomaterial failure. Persistent M1 polarization can drive chronic inflammation, granulation, and fibrotic encapsulation, while M2 polarization is associated with tissue remodeling, wound healing, regeneration and improved integration of biomaterials [4]. Macrophage responses are influenced by implant material type, and physical properties such as size, pore structure, and surface texture. Sterilization methods can also affect these responses by affecting lasting biochemical changes or leaving chemical residues [5]. Secretions of the macrophage cell are sensitive to features like material topography [6].Understanding and controlling macrophage polarization has become one of the key objectives in the design of next-generation biomaterials, implants, and tissue engineering scaffolds. In titanium implants, this response is further complicated by interactions with mesenchymal stem cells, bone-forming osteoblasts, bone-resorbing osteoclasts, gingival fibroblasts, periodontal ligament cells, endothelial cells, and other resident or recruited immune cells, as well as by local inflammatory and microbial stimuli. Therefore, some factors may primarily reflect classical inflammatory activation, while others may be more directly related to tissue remodeling, osteointegration, angiogenesis, foreign body response, or communication with bone-resident cells.
For this reason, the scanned parameters include both canonical macrophage polarization regulators and biomaterial-relevant environmental features. Pro-inflammatory mediators such as IFN-, TNF, IL12, iNOS, CXCL9, and mCXCL10 are included because they may indicate sustained M1-like activation, which can promote immune cell recruitment and inflammatory signaling around the biomaterials. In contrast, IL4, IL10, ARG1, VEGF, STAT6, IRF4, and PPAR represent regulatory, repair-associated, or M2-like pathways that may support vascularization, matrix remodeling, and resolution of inflammation. These features are particularly relevant in titanium implant systems in bone, where successful osseointegration requires a balanced immune response that permits bone formation rather than persistent inflammatory degradation or fibrosis. By scanning these parameters systematically, the surrogate model can identify which macrophage genes are most predictive of favorable or unfavorable immune states. This provides a mechanistic basis for determining which biological factors should be prioritized in future experimental studies.
Methods
Simulation Dataset Generation
To explore macrophage regulatory mechanisms relevant to biomaterial environments, we constructed simulation datasets that systematically toggle key signaling inputs associated with the foreign body response.
Using the COPASI macrophage polarization model from Zhao et al. [8], we generated simulation conditions in which pathway inputs were selectively varied. Specifically, datasets were constructed by modulating signaling drivers associated with inflammatory activation, including IFN-/JAK–STAT1, and IL12/STAT4 pathways; tissue-repair and wound-healing responses, including IL4/IL4R–STAT6–IRF4, IL10/STAT3, ARG1-associated arginine metabolism, and VEGF/VEGFR2 signaling; and environmental stress responses such as hypoxia/HIF-1 signaling. These toggled inputs allow the simulations to capture macrophage behavior across a spectrum of immune responses, ranging from strongly inflammatory to pro-regenerative states.
By systematically varying these regulatory inputs across simulations, we produced datasets that reflect diverse immune microenvironments encountered during implant integration and foreign body response. This design enables downstream machine learning models to identify genes and regulatory pathways that most strongly influence macrophage polarization outcomes under implant-relevant conditions.
The training set will consist of 50, 000+ unique combinations of environmental, regulatory, or transcription factors and the corresponding time course of the polarization system. This diverse dataset will enable the downstream analysis in two major ways: SHAP values allow us to rank the relative importance between the outcome of one feature and the conditions prescribed by each of the others, and extrapolate the model to unseen states and explore pathologically preferred states.
Mechanistic Model Summary
From the 34 functionally unique basis species, the largest expansion in node count arises from the shared signaling hub JAK (18 derived nodes), which reflects its combinatorial engagement across both IL–4 and IFN– receptor complexes. STAT1 and IL4R are the next most expansive (9 derived nodes each), according to multiple phosphorylation, dimerization, trafficking, and nuclear shuttling states; IL4 (8 nodes), IFNGR and STAT6 (7 nodes each), and IFN– (6 nodes) follow. Moderate expansion occurs for core feedback regulators (SOCS1 and SOCS3: 5 nodes each) and for hypoxia transcriptional factors (HIF1, HIF2, and IRF9: 4 nodes each). In contrast, classical effector molecules appear as single-state outputs (ARG1, iNOS, IL12, TNF, CXCL9, VEGF, mCXCL10). Consistent with macrophage polarization biology, expansion targets associated with pro-inflammatory M1 programming (e.g. IFN–, STAT1, IRF1, iNOS, IL12, CXCL9, mCXCL10) tend to expand through distinct signal-processing cascades [27], while M2–associated regulators (e.g. IL4, STAT6, IRF4, ARG1, IL10, PPAR, VEGF) expand through IL–4–centric alternative-activation modules [28].
| Category | Unique Species (basis set) |
| Cytokines | IL4, IFN, IL10, IL12, TNF, VEGF |
| Receptors | IL4R, IFNGR |
| Kinase Signaling Core | JAK, AKT |
| STAT Transcription Factors | STAT1, STAT6 |
| SOCS Regulators | SOCS1, SOCS3 |
| Interferon Regulatory Factors | IRF1, IRF4, IRF9 |
| Hypoxia / Oxygen Sensing | HIF1, HIF2, HIF1, PHD, O |
| Downstream Metabolic Machinery | IRG1, Itaconate, PTEN |
| miRNA Layer (post-transcriptional control) | miR93, miR3473, mPTEN (mRNA), mIRF9 (mRNA) |
| Immune Effector Enzymes | iNOS, ARG1 |
| Nuclear Hormone Receptor | PPAR |
| Chemokine Outputs | CXCL9, mCXCL10 (mRNA) |
Table 2. The 34 functionally–unique species that form the basis from which all 80 ODE model nodes are derived.
Surrogate Model
The workflow and model used to train this data is summarized in Figure 1. We employed a Long Short-Term Memory (LSTM) architecture to learn the full temporal evolution of cytokine and transcription factor concentrations. The model operates on time-resolved input sequences and predicts the corresponding sequence of downstream states, enabling the capture of dynamic regulatory interactions and temporal dependencies inherent to macrophage polarization. Unlike static feedforward models, this framework learns the evolution of system state over time, enabling prediction of full concentration trajectories rather than terminal outputs alone.

Figure 1. Diagram of the full surrogate LSTM workflow used to model the temporal dynamics of the macrophage system.
LSTM Architecture
Each sample is represented as a multivariate time series
where contains cytokine, chemokine, transcription factor, and environmental features at time . The model is trained in a sequence-to-sequence (next-step prediction) setting, learning the mapping
The temporal evolution of the system is encoded using an LSTM:
where is the hidden state and is the cell state capturing long-term dependencies. The LSTM acts as a latent dynamical encoder, integrating historical signaling information and capturing time-dependent regulatory effects.
At each time step, the latent state is mapped to predicted outputs via a feedforward neural network (the latent neural network, LNN):
where consists of fully connected layers with nonlinear activation functions. This mapping translates the learned latent representation into observable concentrations of target molecular species.
The model is trained to minimize the discrepancy between predicted and true trajectories across all time steps using an loss:
This formulation enables the model to learn a latent dynamical system in which the hidden state represents the evolving regulatory state of the macrophage system. By incorporating temporal context, the LSTM captures history-dependent effects, nonlinear interactions, and delayed responses that are not accessible to static models. This is particularly important for immune signaling, where prior exposure to cytokines and transcriptional regulators influences subsequent system behavior.
The learned latent representation provides a basis for downstream interpretability analyses, including SHAP-based feature attribution and ICE/PDP-based functional interrogation, allowing both global importance and context-dependent interactions to be quantified within a unified modeling framework.
Workflow Summary
The predictive model was implemented in PyTorch as a sequence-to-sequence architecture. Input data consisted of multivariate time series of cytokine and transcription factor concentrations, which were standardized using a zero-mean, unit-variance transformation across all timepoints. The model comprises a multi-layer Long Short-Term Memory (LSTM) network with hidden dimension 128, followed by fully connected layers that map latent temporal representations to predicted output trajectories.
Training was performed using the Adam optimizer (learning rate = ) with an loss function applied across all predicted timepoints. Gradient clipping was employed to stabilize training. Models were trained for 75 epochs with a batch size of 32, using a 70/30 train–test split. Model performance was evaluated using mean absolute error and metrics computed both across the full predicted sequence and at the final timepoint. Training and validation losses, along with per-target scores, were tracked throughout training to monitor convergence and predictive fidelity.
Feature importance and interaction effects were analyzed using SHAP values computed via GradientExplainer, alongside ICE and PDP analyses. Together, these methods provide complementary perspectives: SHAP quantifies
Inferring Factor Importance
global feature relevance, while ICE/PDP analyses reveal the structure of learned nonlinear relationships and higher-order interactions within the modeled biological system.
Results
Surrogate LSTM Model Performance
The surrogate models are trained using data generated via COPASI parameter scans. Key parameters—including interferon-γ concentration, IFN-γ (), IL-12 (), and other cytokine inputs—are co-varied across wide biologically relevant ranges to create a heterogeneously distributed training set spanning diverse macrophage activation states.
To assess model performance, an LSTM model was trained to predict all thirteen outputs. Figure 4 shows rapid convergence of both training and test loss. The corresponding scores for each predicted target also quickly approach 1.0, indicating that the model reliably reconstructs the simulated temporal dynamics and captures the underlying regulatory structure of the system.

Figure 4. ICE and PDP analysis for STAT1 prediction across key regulators. Gray lines represent individual conditional expectation (ICE) curves, the blue line shows the partial dependence plot (PDP), and the shaded region denotes the 95% confidence interval. Strong nonlinear and threshold-like responses are observed for pro-inflammatory cytokines (iNOS, TNF, mCXCL10), while VEGF and IFNG exhibit relatively weak marginal effects. Substantial variability across ICE curves highlights context-dependent regulatory dynamics.

Figure 2. Training and validation loss (left) and scores (right) for the neural network model predicting thirteen marker feature trajectories.
SHAP Feature Attribution
To investigate the contribution of individual input features to the model output, SHAP values were computed for each predicted molecular species. STAT1 is presented as a representative example because it is a central regulator of inflammatory macrophage activation. The corresponding SHAP summary plots are shown in Figure 4.
The SHAP analysis reveals that STAT1 prediction is strongly influenced by both inflammatory effector molecules and transcriptional regulators. Among the cytokine and chemokine features, iNOS, TNFα, and mCXCL10 exhibit the largest absolute SHAP values. High values of these features generally contribute positively to predicted STAT1 concentrations, consistent with coordinated activation of the IFN-γ/JAK/STAT1 inflammatory program. In contrast, high VEGF values produce predominantly negative contributions, indicating an inverse relationship between reparative or pro-angiogenic signaling and predicted STAT1 activity.
Within the transcription factor group, STAT1 itself has the largest SHAP contribution, reflecting the strong autoregulatory dynamics represented in the mechanistic model and learned by the surrogate. STAT6 displays a broad bidirectional distribution of SHAP values, consistent with context-dependent competition between inflammatory and alternative activation programs. IRF1, IRF4, and IRF9 have smaller SHAP magnitudes, suggesting that their predictive roles are secondary or become prominent only under particular molecular conditions.
The spread and asymmetry of the SHAP distributions further indicate that these relationships are nonlinear. High levels of the dominant inflammatory regulators can produce disproportionately large increases in predicted STAT1 output, while the direction and magnitude of several lower-ranked features depend on the surrounding cytokine and transcription-factor environment.
Inferring Factor Importance

Figure 3. SHAP summary plots for STAT1 prediction using the LNN–LSTM model. Left: cytokines and chemokines. Right: transcription factors. Features are ranked by mean absolute SHAP value, with color indicating relative feature magnitude. Pro-inflammatory mediators (iNOS, TNF, mCXCL10) and STAT1 itself emerge as dominant drivers, highlighting both upstream signaling and autoregulatory effects.
ICE and Partial Dependence Analysis
Although SHAP identifies which features most strongly contribute to STAT1 prediction, it does not by itself show how the predicted response changes across the range of each feature. Individual conditional expectation (ICE) curves and partial dependence plots (PDPs) were therefore used to examine the learned response functions for selected high-ranking regulators.
The ICE curves illustrate the response of predicted STAT1 concentration to perturbations in individual features, while the PDP represents the population-averaged effect with associated confidence intervals. These results are shown in Figure 4.
Across multiple features, the PDPs reveal distinct nonlinear and threshold-like behaviors. For strongly influential inflammatory features such as iNOS, TNF, and mCXCL10, the predicted STAT1 response remains relatively stable across a broad input range before increasing sharply beyond an intermediate feature value. These patterns suggest that the surrogate has learned switch-like activation dynamics in which STAT1 remains comparatively stable until sufficient inflammatory signaling accumulates.
In contrast, VEGF and IFNG display relatively flat population-averaged PDP responses. Their limited marginal effects do not indicate that these features are biologically unimportant. Rather, the substantial spread among their ICE curves demonstrates that their effects vary across individual simulated conditions and depend strongly on the surrounding regulatory state.
Several ICE trajectories also exhibit abrupt transitions around intermediate input values. These transitions indicate potential regime shifts in the learned dynamics, where small changes in a molecular feature can produce large changes in STAT1 output under particular cytokine environments. The widening confidence intervals near these transition regions further indicate increased heterogeneity and sensitivity. Together, the SHAP and ICE/PDP results distinguish globally influential features from context-dependent effects and identify input ranges in which the system may be especially responsive to perturbation.
Discussion and Conclusions
The results of this study demonstrate the effectiveness of surrogate neural models in capturing the complex, nonlinear behavior of macrophage polarization dynamics under varying microenvironmental conditions. The LSTM surrogate achieved strong prediction accuracy across thirteen key molecular markers, as evidenced by low training and validation losses and uniformly high scores. This confirms the model’s capacity to generalize across the wide range of conditions generated through COPASI simulations, including varied hypoxia and regulatory input levels.
Polarization is governed by a complex network of signaling pathways, transcriptional programs, and metabolic rewiring. Canonical markers of M1 macrophages include iNOS, TNF, IL-12, and IFN-, while M2 macrophages express ARG1, IL-10, VEGF, and TGF [19]. Environmental context, particularly oxygen availability, significantly shapes these phenotypic trajectories. Hypoxic conditions—common in tumor microenvironments, sites of chronic inflammation, and ischemic tissues—affect macrophage function through hypoxia-inducible factors such as HIF-1 and HIF-2, which modulate both metabolic and immune responses [20, 21].
In this study, a data-driven model was developed to learn macrophage polarization behavior from synthetic time-series data generated through simulations of the underlying molecular signaling network. SHAP quantified the contributions of individual molecular features to the surrogate predictions, while ICE and PDP analyses characterized the direction, nonlinearity, and context dependence of the learned relationships. To place the influential features in a broader biological context, the corresponding gene list was examined using Reactome pathway and Gene Ontology biological process enrichment analyses. The reported analyses use over-representation analysis (ORA), with Benjamini–Hochberg false discovery rate (BH FDR) correction within each annotation collection and a significance threshold of 0.05. Reactome pathway enrichment, gene–pathway membership, and GO biological process enrichment are presented in Figure 5–Figure 7.

Figure 5. Enriched Reactome pathways associated with the top influential genes list. Displayed terms meet BH FDR and are ordered by adjusted -value. Dot size indicates the number of overlapping input genes, and color represents . Fold enrichment is , where and are the numbers of input genes in the term and tested input genes, respectively, and and are the corresponding background counts. The exploratory background comprises database-annotated human genes.

Figure 7. Enriched Gene Ontology biological processes associated with the analyzed gene list. Displayed terms meet BH FDR and are ordered by adjusted -value. Dot size denotes the number of overlapping input genes, color denotes , and the horizontal axis shows fold enrichment relative to database-annotated human genes. Multiple-testing adjustment is performed within the GO collection. Enrichment indicates over-representation of annotations without establishing the direction of a biological response.
Among the displayed Reactome results, Interleukin-4 and Interleukin-13 signaling has the strongest statistical enrichment, followed by Signaling by Interleukins, Interleukin-10 signaling, and Interleukin-12 family signaling (Figure 5). These terms contain nine, eleven, five, and five overlapping input genes, respectively. Additional enriched terms include Interleukin-12 signaling, Regulation of IFNG signaling, Interferon gamma signaling, Interferon alpha/beta signaling, and Chemokine receptors bind chemokines. Thus, the analyzed features span inflammatory, alternative-activation, and immunoregulatory cytokine networks. This breadth is consistent with the interacting signaling programs underlying macrophage plasticity [31, 32].
The gene–pathway matrix identifies the annotations underlying these results (Figure 6). STAT1 is shared across several interleukin and interferon terms, while IL4 and STAT6 contribute to the IL-4/IL-13 term. CXCL9 and CXCL10 account for the displayed chemokine-binding enrichment. The matrix also shows that inflammatory-associated genes, including NOS2 and TNF, occur within the IL-4/IL-13 annotation. Membership therefore identifies participation in an annotated pathway without specifying an activating or inhibitory role. Repeated genes across terms also mean that the enriched pathways are overlapping biological descriptions rather than independent signals, and their enrichment ranking should be interpreted separately from the SHAP feature ranking.

Figure 6. Input-gene membership in the enriched Reactome pathways. Filled cells indicate an annotation linking an input gene to a pathway; pale cells indicate no corresponding annotation. Gene symbols correspond to model variables including NOS2 (iNOS), TNF (TNF), CXCL10 (mCXCL10), VEGFA (VEGF), and IFNG (IFN). IL12 is represented by IL12A and IL12B; overlap counts therefore refer to mapped genes rather than the number of model features.
GO enrichment emphasizes cell surface receptor signaling pathway via JAK-STAT, cell surface receptor signaling pathway via STAT, and positive regulation of cytokine production as the three most statistically enriched displayed processes (Figure 7). Terms involving STAT tyrosine phosphorylation further connect the gene list to cytokine-dependent signal transduction. Other enriched processes include response to virus, positive regulation of immune effector process, cell killing, regulation of cell adhesion, regulation of hemopoiesis, endothelial cell proliferation, and regulation of cellular respiration. These annotations place the SHAP findings within a broader network of immune signaling, vascular regulation, and metabolism.
The prominence of JAK–STAT and interferon-related annotations is consistent with STAT1 being the strongest SHAP predictor and with the generally positive contributions of high iNOS, TNF, and mCXCL10 values to predicted STAT1 output. These associations describe a coordinated inflammatory state in the simulated trajectories. Mechanistic modeling of LPS-stimulated macrophages has identified IFN--dependent IRF1 activation as a major determinant of iNOS induction, with TNF contributing to response dynamics [30]. Experimental evidence likewise establishes the importance of IRF1 for this output: stimulated IRF1-deficient murine macrophages produce little or no nitric oxide and exhibit markedly reduced iNOS mRNA [36].
The TNF and chemokine associations also have relevant biological precedents. TNF can initiate an IRF1-dependent, IFN--mediated autocrine loop that sustains inflammatory gene expression and promotes delayed STAT1 expression in macrophages [34]. The enrichment of both type I and type II interferon annotations is also compatible with evidence that IFN-, as well as type I interferons, can induce promoter binding by the STAT1/STAT2/IRF9 complex in murine macrophages [35]. These studies provide context for the STAT1-associated inflammatory and chemokine features without establishing that every cited molecular mechanism is resolved by the surrogate.
The strong enrichment of IL-4/IL-13 and IL-10 signaling broadens this interpretation beyond inflammatory activation. In particular, the bidirectional SHAP distribution of STAT6 is compatible with context-dependent relationships between the IFN-/STAT1 and IL-4/STAT6 branches. The accompanying IL-12-related annotations place these relationships within a wider cytokine network. This interpretation accords with the balance among inflammatory, alternative-activation, and
immunoregulatory programs described in macrophage polarization studies [31, 32]. Enrichment of these terms does not by itself identify which program is dominant in an individual simulated trajectory; that interpretation depends on the feature values and the SHAP and ICE/PDP responses.
The GO terms involving endothelial cell proliferation provide a functional context for the contribution of VEGF. High VEGF values have predominantly negative SHAP contributions, associating them with lower predicted STAT1 output under the sampled conditions. A relevant biological precedent is the delayed inhibition of VEGF-A translation by the IFN--activated inhibitor of translation (GAIT) complex in human monocytic cells [37]. This mechanism supports a possible connection between interferon signaling and reduced angiogenic output, but it does not establish VEGF as an upstream inhibitor of STAT1. Similarly, the enrichment of regulation of cellular respiration provides a broader metabolic context for IRF1-associated effects. Silencing IRF1 reduces IRG1 expression and itaconic acid production in macrophages [33].
Because the analyzed features originate from a mechanistically selected macrophage network, enrichment against a broad database-annotated background should be interpreted as an exploratory assessment of biological coherence. The figures support a pathway-centered interpretation of the learned associations, while the direction and context dependence of the predictions remain grounded in SHAP and ICE/PDP rather than in enrichment significance alone.
The ICE and PDP results extend this interpretation by showing that feature importance does not imply a uniform effect across all simulated states. For iNOS, TNF, and mCXCL10, threshold-like response curves identify ranges in which inflammatory signaling may produce disproportionately large increases in STAT1 activity. By contrast, the flatter population-averaged effects of VEGF and IFNG conceal substantial differences among individual ICE trajectories. These findings support the conclusion that macrophage polarization is governed by a balance of signals whose effects depend on their relative abundance and cellular context rather than on the exclusive presence of individual markers.
The combination of feature ranking and response-curve analysis also provides a basis for future therapeutic research. The feature ranking and pathway analysis results should not be interpreted as a direct prescription for intervention, because SHAP values describe predictive contributions within the modeled system rather than establishing causal therapeutic effects. However, the rankings can prioritize candidate pathways for targeted perturbation studies. Highly ranked upstream regulators such as IFN, JAK signaling, TNF, and IL-4 may motivate experiments that test broad shifts between inflammatory and repair-associated states. Downstream regulators and readouts such as IRF1, iNOS, CXCL9, and mCXCL10 may support more selective interventions or provide biomarkers for determining whether a proposed treatment successfully alters pathway activity.
The nonlinear regions identified by ICE and PDP analysis may be especially useful for designing these experiments. Rather than testing only the presence or absence of a perturbation, future studies could concentrate measurements around predicted transition ranges where small changes in regulator abundance produce large changes in STAT1 output. Combinatorial perturbations could further determine whether these transitions are preserved, shifted, or eliminated when competing pathways are activated simultaneously. Experimental validation through cytokine administration, receptor blockade, gene knockdown, or pharmacological inhibition would help distinguish causal regulators from correlated markers of the same polarization state.
More broadly, the modeling paradigm is adaptable to different levels of biological resolution. It can be expanded by incorporating additional pathways, cell types, environmental variables, or intercellular signaling mechanisms to study novel regulatory networks and emergent immune behavior.
Conversely, the same framework can be narrowed to investigate a smaller pathway or therapeutic question with greater precision. A focused mechanistic model could densely sample a limited set of parameters, incorporate detailed receptor and transcription-factor kinetics, and generate fine-tuned explanations for a specific drug target or regulatory interaction. This flexibility permits the framework to serve either as a broad hypothesis-generation platform or as a targeted computational experiment for resolving subtle pathway-specific effects.
Overall, this study supports the utility of machine-learned surrogates not only for fast, high-fidelity prediction but also for biologically grounded hypothesis generation through explainable artificial intelligence. The ability to combine global feature attribution with individualized and population-averaged response curves provides a principled framework for uncovering regulatory hierarchies, nonlinear transition regions, and context-dependent effects in complex immune networks. Future work may extend this framework to stochastic or single-cell simulations, incorporate symbolic regression to extract compact analytical representations, and integrate experimental perturbation assays. These directions may help bridge computational predictions with wet-lab immunology and enable increasingly targeted modulation of macrophage responses in disease.
References
- [1]Murray, P.J., Allen, J.E., Biswas, S.K., Fisher, E.A., Gilroy, D.W., Goerdt, S., Gordon, S., Hamilton, J.A., Ivashkiv, L.B., Lawrence, T. & Locati, M. (2014). Macrophage activation and polarization: nomenclature and experimental guidelines. Immunity, 41(1), 14-20.
- [2]Mantovani, A., Sica, A., Sozzani, S., Allavena, P., Vecchi, A., & Locati, M. (2004). The chemokine system in diverse forms of macrophage activation and polarization. Trends in immunology, 25(12), 677-686.pubmed.ncbi.nlm.nih.gov/15530839
- [3]Mantovani, A., Garlanda, C., & Locati, M. (2009). Macrophage diversity and polarization in atherosclerosis: a question of balance. Arteriosclerosis, thrombosis, and vascular biology, 29(10), 1419-1423.DOI
- [4]Anderson, J. M., Rodriguez, A., & Chang, D. T. (2008, April). Foreign body reaction to biomaterials. In Seminars in immunology (Vol. 20, No. 2, pp. 86-100). Academic Press.DOI
- [5]Boersema, G. S., Grotenhuis, N., Bayon, Y., Lange, J. F., & Bastiaansen-Jenniskens, Y. M. (2016). The effect of biomaterials used for tissue regeneration purposes on polarization of macrophages. BioResearch open access, 5(1), biores-2015.DOI
- [6]Chen, S., Jones, J. A., Xu, Y., Low, H. Y., Anderson, J. M., & Leong, K. W. (2010). Characterization of topographical effects on macrophage behavior in a foreign body response model. Biomaterials, 31(13), 3479-3491.DOI
- [7]Avila-Ponce de León, U., Vázquez-Jiménez, A., Padilla-Longoria, P., & Resendis-Antonio, O. (2023). Uncoding the interdependency of tumor microenvironment and macrophage polarization: insights from a continuous network approach. Frontiers in Immunology, 14, 1150890.
- [8]Zhao, C., Mirando, A. C., Sové, R. J., Medeiros, T. X., Annex, B. H., & Popel, A. S. (2019). A mechanistic integrative computational model of macrophage polarization: Implications in human pathophysiology. PLoS computational biology, 15(11), e1007468.DOI
- [10]Zhang, Y., Wang, H., Oliveira, R. H. M., Zhao, C., & Popel, A. S. (2022). Systems biology of angiogenesis signaling: Computational models and omics. WIREs Mechanisms of disease, 14(4), e1550.DOI
- [11]Wang, H., Zhao, C., Santa-Maria, C. A., Emens, L. A., & Popel, A. S. (2022). Dynamics of tumor-associated macrophages in a quantitative systems pharmacology model of immunotherapy in triple-negative breast cancer. IScience, 25(8).DOI
- [12]Cess, C. G., & Finley, S. D. (2020). Multi-scale modeling of macrophage—T cell interactions within the tumor microenvironment. PLoS computational biology, 16(12), e1008519.DOI
- [13]Torres, M., Wang, J., Yannie, P. J., Ghosh, S., Segal, R. A., & Reynolds, A. M. (2019). Identifying important parameters in the inflammatory process with a mathematical model of immune cell influx and macrophage polarization. PLoS computational biology, 15(7), e1007172.DOI
- [14]Guo, X., Adelaja, A., Singh, A., Wollman, R., & Hoffmann, A. (2025). Modeling heterogeneous signaling dynamics of macrophages reveals principles of information transmission in stimulus responses. Nature Communications, 16(1), 5986.DOI
- [15]Zerrouk, N., Alcraft, R., Hall, B.A. et al. Large-scale computational modelling of the M1 and M2 synovial macrophages in rheumatoid arthritis. npj Syst Biol Appl 10, 10 (2024). https://doi.org/10.1038/s41540-024-00337-5
- [16]Lundberg, S. M., Erion, G., Chen, H., DeGrave, A., Prutkin, J. M., Nair, B., Katz, R., Himmelfarb, J., Bansa, N., & Lee, S. I. (2020). From local explanations to global understanding with explainable AI for trees. Nature machine intelligence, 2(1), 56-67.
- [17]Goldstein, A., Kapelner, A., Bleich, J., & Pitkin, E. (2015). Peeking inside the black box: Visualizing statistical learning with plots of individual conditional expectation. journal of Computational and Graphical Statistics, 24(1), 44-65.
- [18]Hoops, S., Sahle, S., Gauges, R., Lee, C., Pahle, J., Simus, N., Singhal, M., Xu, L., Mendes, P., & Kummer, U. (2006). COPASI—a complex pathway simulator. Bioinformatics, 22(4), 3067-3074.pubmed.ncbi.nlm.nih.gov/17032683
- [19]Lawrence, T., & Natoli, G. (2011). Transcriptional regulation of macrophage polarization: enabling diversity with identity. Nature reviews immunology, 11(11), 750-761.DOI
- [20]Nizet, V., & Johnson, R. S. (2009). Interdependence of hypoxic and innate immune responses. Nature Reviews Immunology, 9(9), 609-617.DOI
- [21]Palazon, A., Goldrath, A. W., Nizet, V., & Johnson, R. S. (2014). HIF transcription factors, inflammation, and immunity. Immunity, 41(4), 518-528.DOI
- [27]Mills, C. D., Kincaid, K., Alt, J. M., Heilman, M. J., & Hill, A. M. (2000). M-1/M-2 macrophages and the Th1/Th2 paradigm. The Journal of immunology, 164(12), 6166-6173.pubmed.ncbi.nlm.nih.gov/10843666
- [28]Mantovani, A., Sica, A., Sozzani, S., Allavena, P., Vecchi, A., & Locati, M. (2004). The chemokine system in diverse forms of macrophage activation and polarization. Trends in immunology, 25(12), 677-686.pubmed.ncbi.nlm.nih.gov/15530839
- [30]Salim T, Sershen CL, May EE. Investigating the Role of TNF-α and IFN-γ Activation on the Dynamics of iNOS Gene Expression in LPS Stimulated Macrophages. PLoS One. 2016 Jun 8;11(6):e0153289. doi: 10.1371/journal.pone.0153289. PMID: 27276061; PMCID: PMC4897855.DOI
- [31]Sica A, Mantovani A. Macrophage plasticity and polarization: in vivo veritas. J Clin Invest. 2012 Mar;122(3):787-95. doi: 10.1172/JCI59643. Epub 2012 Mar 1. PMID: 22378047; PMCID: PMC3287223.DOI
- [32]Wang N, Liang H, Zen K. Molecular mechanisms that influence the macrophage m1-m2 polarization balance. Front Immunol. 2014 Nov 28;5:614. doi: 10.3389/fimmu.2014.00614. PMID: 25506346; PMCID: PMC4246889.DOI
- [33]Tallam A, Perumal TM, Antony PM, Jäger C, Fritz JV, Vallar L, Balling R, Del Sol A, Michelucci A. Gene Regulatory Network Inference of Immunoresponsive Gene 1 (IRG1) Identifies Interferon Regulatory Factor 1 (IRF1) as Its Transcriptional Regulator in Mammalian Macrophages. PLoS One. 2016 Feb 12;11(2):e0149050. doi: 10.1371/journal.pone.0149050. PMID: 26872335; PMCID: PMC4752512.DOI
- [34]Yarilina A, Park-Min KH, Antoniv T, Hu X, Ivashkiv LB. TNF activates an IRF1-dependent autocrine loop leading to sustained expression of chemokines and STAT1-dependent type I interferon-response genes. Nat Immunol. 2008 Apr;9(4):378-87. doi: 10.1038/ni1576. Epub 2008 Mar 16. PMID: 18345002.DOI
- [35]Platanitis E, Demiroz D, Schneller A, Fischer K, Capelle C, Hartl M, Gossenreiter T, Müller M, Novatchkova M, Decker T. A molecular switch from STAT2-IRF9 to ISGF3 underlies interferon-induced gene transcription. Nat Commun. 2019 Jul 2;10(1):2921. doi: 10.1038/s41467-019-10970-y. PMID: 31266943; PMCID: PMC6606597.DOI
- [36]Kamijo R, Harada H, Matsuyama T, Bosland M, Gerecitano J, Shapiro D, Le J, Koh SI, Kimura T, Green SJ, et al. Requirement for transcription factor IRF-1 in NO synthase induction in macrophages. Science. 1994 Mar 18;263(5153):1612-5. doi: 10.1126/science.7510419. PMID: 7510419.DOI
- [37]Ray PS, Fox PL. A post-transcriptional pathway represses monocyte VEGF-A expression and angiogenic activity. EMBO J. 2007 Jul 25;26(14):3360-72. doi: 10.1038/sj.emboj.7601774. Epub 2007 Jul 5. PMID: 17611605; PMCID: PMC1933405.DOI