# Predictive Analysis for Optimizing Port Operations
## 3 Case Study and Methodology
Class 0 (Low) is defined for vessels with Total Time at port for 0-25 h, Class 1 (Medium) is defined for 25-50 h, Class 2 (High) includes 50-75 h, and Class 3 (Very High) is \(>\)75 h. For the Delay Class shown in Figure 1b, the plots and summary statistics (mean Delay Time \(\approx\) 10 h, variance of Delay Time \(\approx\) 125) are used to define class 0 as Delay Time \(<\) 24 h and Class 1 as Delay Time \(>\) 24 h.  
In the realm of supervised learning for prediction and classification, tree-based methods, statistics-based methods, and deep learning represent three prominent approaches, each with its own strengths and applications. In this study, we apply these methods for the predictive analysis of ports, focusing on modeling vessel Stay (Total) Time and Delay Time. We will briefly explore these different approaches and discuss the metrics used to evaluate their performance. Tree-based algorithms, such as Random Forest, Extreme Gradient Boosting (XGBoost), AdaBoost, Light Gradient Boosting Machine (LightGBM), and Extra Trees, are known for their ability to handle complex relationships in data and provide robust predictions. Random Forest, for instance, constructs multiple decision trees and aggregates their outputs to improve accuracy and reduce overfitting [31]. XGBoost is a gradient boosting algorithm that excels in optimizing complex objective functions and has been widely used in competitions and industry applications for its performance [32]. AdaBoost focuses on iteratively boosting the performance of weak learners to achieve strong predictive models [33]. LightGBM is known for its efficiency in handling large datasets and has become popular for its speed and accuracy [34]. Extra Trees or Extremely Randomized Trees is an ensemble learning method that builds multiple decision trees and averages their predictions, providing robustness against noise and overfitting [35]. Additionally, feature importance analysis in tree-based models helps identify the most influential variables in the prediction process, providing insights into the underlying patterns in the data [36]. On the other hand, statistics-based methods like regression, Support Vector Machine (SVM), Bayesian classifiers, k-Nearest Neighbor (kNN), and Elastic Net offer a different set of tools for prediction and classification tasks. Regression techniques, including linear regression and its variants, are widely used for predicting continuous outcomes based on the relationships between variables [37]. SVM is a powerful predictive method that aims to find the optimal hyperplane that best separates data points into different regions in a high-dimensional space [38]. Bayesian classifiers are based on [PERSON] theorem and are probabilistic models that calculate the probability of a sample belonging to a particular class [39]. kNN is a simple yet effective algorithm that classifies a data point based on the majority class of its nearest neighbors in the feature space [40]. Elastic Net is a regularization technique combining L1 (Lasso) and L2 (Ridge) penalties, which is particularly useful for feature selection and dealing with multicollinearity in regression and classification problems [41]. Each of these statistics-based methods has its own assumptions, strengths, and limitations, making them suitable for different types of datasets and prediction tasks. In contrast, deep learning approaches like neural networks [42; 43] and ResNet (Residual Network) [44] can learn complex relationships present in the data. Neural networks consist of layers of interconnected nodes that can model intricate patterns and interactions between variables, making them highly effective for both classification and prediction tasks. ResNet is a type of deep neural network that introduces skip connections to enable the  
Figure 1: Distribution of Total Time and Delay Time at port. training of very deep models by mitigating the vanishing gradient problem, allowing it to capture even more complex data relationships.