India Mähler
Development and Application of Modern Generative AI Methods for Emulating Clinical Studies
India Mähler presents her master's thesis, which she recently defended as part of the applied mathematics degree program at Koblenz University of Applied Sciences. Her thesis was supervised by Prof. Dr. Holger Fröhlich and Prof. Dr. Armin Fiedler.
Background and Motivation
The generation of realistic synthetic data has become increasingly important for improving the design and evaluation of clinical trials. Although randomized controlled trials (RCTs) are considered the gold standard for establishing causal effects, they are expensive, time-consuming, and are often limited by small, selective, and non-representative patient cohorts. These limitations become even more pronounced in studies that require longitudinal, multimodal data with both continuous and categorical variables. Meanwhile, real-world data (RWD) from routine clinical practices are gaining importance. While RWD captures more diverse and realistic disease trajectories, they often contain irregular measurement schedules and missing values, which complicate analysis [1, 2].
A promising approach in this context is trial emulation, which involves structuring existing patient data to replicate the design of a clinical trial. This allows “what if” scenarios to be simulated and potential treatment effects to be estimated without the need to recruit new participants. Trial emulation combines the methodological robustness of RCTs with the diversity of RWD, providing more realistic insights into disease progression and treatment outcomes [3, 4].
The publication by Wendland et al. [5] provides a baseline for generating synthetic data using their Multimodal Neural Ordinary Differential Equations (MultiNODEs) model. Building on this foundation, the aim of the master thesis is to overcome certain limitations of the current model, such as limited flexibility in handling different data types and the lack of support for counterfactual simulations. Furthermore, this thesis seeks to perform counterfactual simulations based on RWD-derived covariates and to compare different hypothetical “what-if” treatment scenarios.
Methods
Dataset
The dataset was obtained from the Pooled Resource Open-Access ALS Clinical Trials (PRO-ACT) Database and includes 3,246 patients who received either placebo (PBO) or treatment (TRT) [6]. For each patient, 75 longitudinal variables were recorded, with a total of 40,949 measurements and a median of 10 measurement time points per patient. In addition, 78 static variables are available. The actual observation period spans from day 0 to day 3,742. However, due to the scale and heterogeneity of the dataset, we define a period of 0 to 500 days to avoid computational constraints.
Treatment-Guided MultiNODEs
The baseline MultiNODEs model (Figure 1) is a hybrid generative AI model that combines NODEs with multimodal data. It is specifically designed to handle both longitudinal (time-dependent) and static variables, and to deal with missing data implicitly [5]. To obtain our final model, Treatment-Guided MultiNODEs, several architectural adaptations were introduced. One key modification was the addition of modular encoders for static and longitudinal inputs. Their latent representations are then concatenated and passed through a multilayer perceptron (MLP) to generate Learnable Initial Conditions (LICs). These LICs serve as the initial input for both the NODE system and the static decoder, enabling the reconstruction of static data directly from the LICs rather than from the static latent space, as the LICs represent the starting point of the system. The model also allows the optional inclusion of additional information on the right-hand side of the NODE. The output of the NODE is then processed by a MLP to reconstruct the longitudinal data. The longitudinal decoder has been adapted to handle multiple data types, including real-valued, positive-valued, categorical, and binary variables, with binary variables modeled via a Bernoulli distribution. Continuous variables follow the original modeling approach. Similarly, the static decoder has been extended to support a broader range of data types beyond categorical variables, including real-valued, positive-valued, categorical, and binary data, with the option to use mean squared error loss for continuous variables.
Results and Conclusion
The results include the real observed data (blue), the simulation outputs (purple), the counterfactuals (red), and the synthetic patient data (green). All plots were generated using the syndat library [7]. Figure 2 presents the counterfactual results for the TRT scenario, meaning the RWD patients are simulated as if they had received the TRT administered in PRO-ACT. Figure 3, in contrast, shows the results for the PBO scenario.
Forced Vital Capacity (FVC) is a continuous variable representing the lung volume that can be exhaled with maximum force after full inhalation [6]. The results show that the model captures the overall trend well and reproduces it accurately across all scenarios. Overall, the simulations perform well for categorical variables such as the ALSFRS variables, while continuous variables show slightly weaker performance The ALSFRS variables provide a standardized assessment of patient’s physical abilities and disease progression, based on ten questions scored from 0 (no function) to 4 (normal function).
In the counterfactual simulations, this pattern is reversed: continuous variables are modeled effectively, and the general trend is well captured, whereas categorical variables perform more poorly. However, they are captured better in the TRT scenario than in the PBO scenario.
The main limitation lies in the limited overlap between the distributions of the RWD and PRO-ACT datasets. This reduces the alignment between the datasets and negatively affects the simulation quality.
Overall, the results demonstrate that Treatment-Guided MultiNODEs can be successfully trained on a clinical trial database composed of multiple studies, despite challenges such as heterogeneous RWD. The simulations perform well overall. For future work, it would be beneficial to better align the RWD and PRO-ACT datasets, for example through propensity score matching, to further improve counterfactual performance.
Citations
[1] Julia Wicherski et al. “Real-world-Daten in der Arzneimittelregulation–aktuelle Entwicklungen und Ausblick”. In: Prävention und Gesundheitsförderung (2023). https://doi.org/10.1007/s11553-022-01010-7
[2] Wedlund, L. & Kvedar, J. Simulated trials: in silico approach adds depth and nuance to the RCT gold-standard. Npj Digit. Med. 4, 121 (2021).
https://doi.org/10.1038/s41746-021-00492-7
[3] Lan Wen and Aaron L Sarvet. “Estimating average treatment effects when treatment data are absent in a target study”. In: arXiv preprint arXiv:2509.22543 (2025). https://doi.org/10.48550/arXiv.2509.22543
[4] Miguel A Hernán, Wei Wang, and David E Leaf. “Target trial emulation: a framework for causal inference from observational data”. In: Jama 328.24 (2022). https://doi.org/10.1001/jama.2022.21383
[5] Wendland, Philipp, et al. "Generation of realistic synthetic data using multimodal neural ordinary differential equations." NPJ Digital Medicine 5.1 (2022): 122. https://doi.org/10.1038/s41746-022-00666-x
[6] Pooled Resource Open‑Access ALS Clinical Trials (PRO-ACT) Database. NCRI Partners / Neurological Clinical Research Institute, Massachusetts General Hospital. https://ncri1.partners.org/ProACT/Document/DisplayLatest/6
[7] Tim Adams and Diego Valderrama. Synthetic data quality evaluation & visualization. https://github.com/SCAI- BIO/syndat/. Version: v0.13.6. 2025.
https://doi.org/10.5281/zenodo.15985027