## 4 Discussion
While the category-based method offers a practical balance by reducing computational time to 53 h, this computational time is still excessive in a TIVA environment, where a daily routine surgery takes between 20 min and 3 h. To assess the real-time applicability of this approach, the focus was on the last category (patients with the highest correlation between inputs and output). The LSTM model was trained on patients in the last category, excluding one patient (Patient 70), to retain unseen data for testing. A simulated real-life scenario was implemented in MATLAB(r), where the trained LSTM received input data (CeProp and CeRemi) and estimated the corresponding MAP every 5 s. These estimations were then compared against the real MAP values. This analysis aims to demonstrate the practical utility of the category-based approach in real-life scenarios. Figure 6(a) shows the estimations from both the category-specific (red) and population-specific models (green) against the actual MAP values (blue). It can be observed that the category-specific method provides better estimation than the population-specific method. Figure 6(b) indicates that the category-specific model's estimations have a distribution closer to the actual MAP values (\(p\)-value = 0.0021), hence capturing better the central tendency and variability in the actual MAP values, leading to more accurate estimations. Despite requiring 53 h for the initial architecture selection and model training, the simulation of real-life scenarios provided feasible and accurate MAP estimations. These results are shown in Figure 7. Despite the lengthy initial computational time, its online estimations are accurate, making it an effective approach for MAP estimation. The simulator proposed in [35] can be used to generate additional data and test the proposed solution before applying it on real data. Figure 7: Results of an online real-life simulation to estimate the MAP values every 5 s of Patient 70. (**a**) LSTM-estimated MAP using the category-specific method using the population-specific method vs. actual MAP values. (**b**) Boxplot representation of real MAP (1), category-specific model estimation (2), and population-specific model estimation (3). To determine the feasibility of using the LSTM model for MAP estimation, an initial assessment of the correlations between CeProp, CeRemi, and MAP is essential. Recording CeProp and CeRemi signals for at least 10 min, which corresponds to the duration from the start of infusion of Remifentanil and Propofol until the start of the incision (including intubation and patient preparation), provides a reliable estimate of the correlation. If the correlation coefficient exceeds 0.4, proceed with the LSTM algorithm for accurate estimation. If below 0.4, estimation may not be feasible, and alternative methods should be considered. This ensures the model is used effectively when a strong input-output relationship is present. **Limitations:**  
* The current study method provides estimation, not forecasting, which means it estimates the MAP value at a particular moment rather than forecasting future values. Although the proposed method offers the advantage of having MAP data that can be sampled as desired, the method could be improved in future research to forecast MAP within a precise prediction horizon. Forecasting MAP values can significantly enhance monitoring capabilities and early warning systems for adverse events. By predicting MAP values, it is possible to enable early detection of potential issues such as hypotension (low blood pressure) [36] and hypertension (high blood pressure) [37], allowing timely interventions to prevent complications. This predictive approach improves patient outcomes by providing healthcare professionals with advanced notice of potential adverse events, facilitating prompt and appropriate responses. * This approach needs an offline process at the start of a TIVA trial to categorize patients based on their correlation and to identify the best model architecture for each category.