## 4 Data Analysis  
The HIV clinical cohort database (HCCD), maintained by Einstein-Rockefeller-CUNY Center for AIDS Research, contains de-identified data on people living with HIV and receiving care at hospitals and clinics affiliated with Montefiore Medical Center, which is the largest provider of HIV care in the Bronx, New York City. Patients in the HCCD are demographically representative with respect to age, sex, race/ethnicity, and HIVtransmission risk of the overall population of people living with HIV in the Bronx that is described by public health surveillance data [29]. For this study, we include all patients living with HIV in HCCD diagnosed between 2005 and 2015 with last follow-up by 31 December 2017. Additional inclusion criteria included age \(\geq\) 13 years and at least two HIV-1 viral loads recorded during the period. The final analytic dataset contains 2475 persons with a median viral load frequency of 5 and an inter-quantile range from 3 to 11. Notably, approximately 60% of the viral load measurements were found to be below the detection limits. In addition to the primary model (2), we also fit a model where the post-ART segment is assumed to follow a two-compartment model [12], which is commonly used for viral load after the treatment. Therefore, we have the following two random change point models:  
M1: \[y_{ij}=a_{1i}(t_{ij}-\tau_{i})^{-}+\log_{10}(b_{1i}e^{-b_{2i}(t_{ ij}-\tau_{i})^{+}}+b_{3i})+e_{ij}.\] M2: \[y_{ij}=a_{1i}(t_{ij}-\tau_{i})^{-}+\log_{10}(b_{1i}e^{-b_{2i}(t_ {ij}-\tau_{i})^{+}}+b_{3i}e^{-b_{4i}(t_{ij}-\tau_{i})^{+}})+e_{ij}.\]  
where M1 allows for individual-specific baseline value \(b_{3i}\) for the second phase of viral decay, while M2 also captures the second phase viral decay rate through the random effects \(b_{4i}\). Our preliminary analysis indicates that it is sufficient to model the pre-change point segment with a linear mixed-effects model and the post-change point segment with a diagonal variance-covariance random effects structure. As a result, we make use of the following assumptions:  
M1: \[\mathbf{a}_{i}\sim N(\alpha,\sigma_{A}^{2}),\quad\mathbf{b}_{i} \sim N((\beta_{1},\beta_{2},\beta_{3})^{T},\text{diag}(\sigma_{B11}^{2},\sigma _{B22}^{2},\sigma_{B33}^{2})),\] \[\tau_{i}\sim ZIE(\tau,\lambda),\quad e_{ij}\sim N(0,\sigma_{e}^{2}).\] M2: \[\mathbf{a}_{i}\sim N(\alpha,\sigma_{A}^{2}),\quad\mathbf{b}_{i} \sim N((\beta_{1},\beta_{2},\beta_{3},\beta_{4})^{T},\text{diag}(\sigma_{B11} ^{2},\sigma_{B22}^{2},\sigma_{B33}^{2},\sigma_{B44}^{2})),\] \[\tau_{i}\sim ZIE(\tau,\lambda),\quad e_{ij}\sim N(0,\sigma_{e}^{2}).\]  
We implemented the StEM algorithm in R [30] with the following tuning parameters: \((w,M,p_{1},p_{2},e)=(10,300,0.1,0.5,1.5)\), where we also restrict \(\beta_{1}>\beta_{3}\) for M2 to ensure the model is identifiable. This configuration typically allows for convergence within 3000 iterations in most model-fitting runs. Owing to the stochastic nature of the StEM algorithm, the choice of starting values is quite flexible, with initial values set randomly within the possible range. To simulate the multivariate truncated normal distribution for the left-censored viral loads, we utilized the R package truncnorm [31]. For the ZIE-distributed change points, we set the value to zero with the current estimated probability \(\pi\), and with probability \(1-\pi\), we set it to a random variable from an exponential distribution with the current estimated mean \(\lambda\). Figures 1 and 2 display the trace plots of the Markov Chains for each parameter under models M1 and M2, respectively. Table 1 summarizes the estimation results for the fixed effects and dispersion parameters for both models. The estimations are comparable between M1 and M2, except for \(\beta_{3}\) which is necessarily smaller in M1 due to the single baseline parameter in the one-compartment model M1. In contrast, this baseline value is estimated to be larger in M2, where it, along with the viral decay rate \(\beta_{4}\), captures the dynamics of the viral trajectory during the second phase.