Mixed effect state space model application for data driven pharmacometrics modeling
Authors: Goo Sungwoo , Lee Soyoung , CHAE Jung-woo , Yun Hwi-yeol 
Published: February 2025

Objectives: According to the advancement of Deep Learning (DL), data-driven modeling method, implemented model by generalized functions, has been introduced in the field of pharmacometrics (PM). In general, since PM models used to be optimized by Linear Time Invariant (LTI) models, State Space Model(SSM) has mathematical similarities.[1] In addition, dataset for PM tend to be grouped by each patient and its inter-individual variation used to be elaborated with population approaches. we implemented a Mixed Effect State Space Model (MESS) for data driven PM modeling. Through this model, the PM profile could be modeled and conducted simulation without any prior domain knowledges, it should be utilized as a reference model when constructing a structural model.Methods: We implemented an SSM solver using PyTorch, a Python deep learning library. To generalize the representation of SSM, we set the A matrix of SSM as a diagonal square matrix and optimized the diagonal components' decay time constants, τ, as parameters.[2] This approach allows for a more generalized representation of SSM. We applied the Mixed Effect model by incorporating Random Effect Variables (REVs) to the components of matrix A related to state decay, matrix B related to input, and matrix C interpreting the state. Optimization was performed using the Adam algorithm, an Expectation-maximization algorithm that maximizes the likelihood.[3] To compare the performances between canonical PM methods and new methods developed by MESS, we generated a simulation datasets by 2-compartment model with 1000 subjects in an IV bolus situation and optimized it with the existing 2-compartment model (with 4 REVs) and 4 types of MESS models (with 1, 2, 3, and 4 states). Additionally, we generated a dataset by simulating a 1-compartment with gut model (with 3 REVs) for 1000 subjects and optimized it with MESS models having 1 to 4 states.Results: As the MESS optimization, the residual standard deviation (SD) was reduced as the number of states increased. We observed that the residual SD increased relatively significantly if the number of states was not large enough. and it would be possible to determine which parts had interindividual variability by identifying the existence of REV SDs greater than 0.001 applied to matrices A, B, and C. In both IV and PO datasets, the VPC trends were similar to the canonical method. When the number of compartments was identical with the number of states, the OFV estimated by MESS model has the least difference from the canonical method's OFV.Conclusions: We demonstrated the possibility for application of data driven PM modeling implemented by MESS model and it could be optimized using smaller datasets compared to existing DL models. Because SSM is specific to LTI systems, it is easier to interpret than other DL models. Data Driven PM modeling should be advanced by incorporated by methods for overfitting discrimination and optimizing the number of REVs. Citations: [1] J. Durbin and S. J. Koopman, Time series analysis by state space methods, vol. 38. OUP Oxford, 2012. [2] A. Gu, K. Goel, and C. Ré, “Efficiently modeling long sequences with structured state spaces,” arXiv preprint arXiv:2111.00396, 2021. [3] D. P. Kingma and J. Ba, “Adam: A Method for Stochastic Optimization.” arXiv, Jan. 29, 2017. doi: 10.48550/arXiv.1412.6980.