This research aims to build an algorithm to monitor vessel activities in Indonesian waters, including incoming and outgoing vessels, duration at port and overseas visits.
We refer to the port area as the Area of Interest (AOI) and we follow the two approaches in identifying the AOI: Distance-Based approach and Cluster-Based approach. The Distance-Based approach is a rule-based approach that defines a port boundary as an area within a specified distance from a predefined center. Meanwhile, the Cluster-Based approach identifies clusters in AIS messages, around which convex polygons are drawn to delimit the AOI. The Distance-Based approach is applied for Indonesian port AOIs using a square centered on the port coordinates where the shortest distance of the center point to the sides of the square is 3.3 km. The Cluster-Based approach is applied for foreign port AOIs using a 22 km square boundary to identify the clusters. This research also developed Standard Operating Procedures (SOPs) for AIS data preprocessing, including validation, detection and handling of missing or inconsistent data, and manual error correction.
Algorithms formed from AIS data can be used as an alternative to sea transportation data, such as the number of domestic and foreign vessel visits to Indonesian ports, the duration of vessels at Indonesian ports and the number of Indonesian vessel visits to foreign ports. Also, the SOPs from this research will improve the accuracy and reliability of AIS data as official statistics, providing added value in operations, market predictions and economic impact analysis of the maritime sector in Indonesia.
This research developed the algorithm using Distance-Based approach and Cluster-Based approach to create AOI, as well as Apache Spark for big data processing. This research also developed SOPs for AIS data preprocessing, including validation, detection and handling of missing or inconsistent data, and manual error correction. One of the steps is to ensure the Maritime Mobile Service Identity format is correct.
1. Introduction
With the rapid development of digital technology, National Statistics Offices around the globe have begun to modernize the national statistical systems by utilizing big data sources to provide high-quality data and make statistical operations more cost-effective (Pramana et al., 2017). One of the big data sources used is the Automatic Identification System (AIS), an automated system for vessel communication and navigation. AIS data allows accurate monitoring of vessel movements, which plays an important role in the safety and regulation of traffic at sea (Haryadi et al., 2019; Karim, 2019; Maulidi, 2019; Van der Wielen et al., 2023).
The use of AIS data has proven effective in generating new statistics, such as vessel traffic monitoring, trade volume estimation and maritime sector economic impact analysis (Asian Development Bank, 2023). It improves the accuracy and reliability of statistics by reducing human error in data collection (Badan Pusat Statistik, 2023; Utami et al., 2024). The utilization of AIS in Indonesia is regulated by the Minister of Transportation Regulation Number 7 of 2019, which requires all vessels in Indonesian waters to use AIS devices and provide correct information (Asian Development Bank, 2023; Penca, 2009; Kim et al., 2023; Simau et al., 2023).
As an archipelagic country with the second-longest coastline in the world, the use of AIS devices in Indonesia is very useful for monitoring activities at sea (Arianto, 2020). One of the benefits is to protect natural resources originating from the sea so that they can be maximally utilized for the welfare of the people. However, there are challenges in tracking small vessels under 24 meters and facing falsification of vessel documents (Indonesia Ocean Justice Initiative, 2021; Maulana, 2017).
On March 31, 2021, the Ministry of Maritime Affairs and Fisheries (KKP) detected 10 illegal vessels in the North Natuna Sea area (Wijayanti et al., 2021). In May 2021, satellite imagery also detected around 50 Vietnamese vessels conducting illegal fishing in the North Natuna Sea area. In addition, according to KKP, approximately 90% of the vessels detected were falsifying vessel volume documents (markdown) (Maulana, 2017).
These phenomena prove the weak supervision of vessel activities and security in Indonesian waters. As a result, foreign vessels or fishermen can easily enter Indonesian waters, especially those from countries directly adjacent to Indonesia. If the authorities do not take preventive measures, the rampant illegal fishing cases that occur in Indonesian waters will continue to occur in the future (Wijayanti et al., 2021).
With AIS, it is possible to monitor illegal actions at sea, such as smuggling and IUU (Illegal, Unreported, Unregulated) fishing. In addition, most large fishing vessels above 24 meters in size can be tracked by AIS. Therefore, the use of AIS is very important for Indonesian maritime affairs.
This research aims to build an algorithm that estimates the number of port calls in Indonesian ports and overseas ports, utilizing AIS data. A port call is a collaborative process in which numerous stakeholders collaborate to efficiently and safely bring vessels into the port, operate on them and then exit the port (Bruijn, 2021). In addition, the duration of a vessel’s stay in Indonesian ports is also estimated. The duration of the vessel at the port in this research is defined as turnaround time. Turnaround time is the time from the arrival of the vessel until the departure of the vessel from the port (Badan Pusat Statistik, 2016).
To ensure data quality, this research includes a preprocessing stage of AIS data. This includes data validation, detection and handling of missing or inconsistent data, and manual error correction. This structured preprocessing stage is expected to improve the accuracy and reliability of AIS data as official statistics, providing added value in operations, market predictions and analysis of the economic impact of the maritime sector in Indonesia.
The article is organized as follows. The next section is a literature review on the use of AIS data in official statistics and the use of the H3 spatial index on AIS records. Section 3 includes a description of the data sources and data processing environment and includes an overview of the UN Global Platform and the methods used to calculate port calls and duration in port. In Section 4, the results are presented. The article then concludes with a discussion of the results and some final comments.
2. Literature review
AIS is a tracking system that can automatically track vessels and their traffic (Haryadi et al., 2019). By using very high frequency transponders, AIS allows vessels to exchange information about navigation or vessel data with their own vessels, other adjacent vessels, AIS base stations, satellites (Satellite AIS/Sat-AIS/S-AIS), or coastal stations and AtoN (Aids to Navigation) (Karim, 2019). Messages broadcasted by AIS devices consist of a nine-digit Maritime Mobile Service Identity (MMSI) number to connect with the public telecommunications network, vessel identity in the form of an International Maritime Organization (IMO) number, vessel position consisting of latitude and longitude, course (Course Over Ground), speed (Speed Over Ground (SOG)) and other information which are then classified into fixed data, dynamic data and other data (Kim et al., 2023).
The information will be received periodically by other vessels, AIS base stations, satellites, or shore stations and AtoN within range of the vessel sending the information. The information from these AIS devices will be processed and graphed on computers or electronic navigation equipment, such as electronic charts or Electronic Chart Display and Information System, using software (Bonham et al., 2018).
BPS Statistics Indonesia has initiated a study to utilize AIS data for producing transportation statistics. In 2023, BPS Statistics Indonesia published guidance on AIS data utilization, including how to define several things related to AIS data processing, such as port definition, vessel-type definition and route definition. For port definition, port point data from the WPI and a bounding box of about 12 miles from the point provided in the WPI are used. To view the vessel types in the dataset accessed through the UN Global Platform (UNGP), users can access the vessel_type column. Finally, for route definition, port activities were identified. Methods include geofencing by creating geofences around the harbor, speed and direction analysis, anchoring activity, specific vessel types and types of AIS messages, such as position reports and navigation status reports (Badan Pusat Statistik, 2023).
Furthermore, the Asian Development Bank revealed the potential of AIS-derived indicators as an alternative to maritime official statistics that can provide important information before maritime official statistics are officially released. Events of Interest and Areas of Interest (AOI) are used as the basic components of these AIS-derived indicators. These methods overcome common challenges in utilizing AIS data, such as data quality, big data processing and identification of geographical boundaries. The research identified shortcomings posed by AIS data, such as potential signal gaps from switched-off transponders, variations in sampling methods, errors in manual input fields, incorrect MMSI or vessel identifiers, and possible falsification or manipulation (Asian Development Bank, 2023).
Bonham et al. conducted research on the utilization of an AIS data approach to predict the likelihood that a ship would be delayed in arriving at a port in the United Kingdom.
In addition, an exploration of the operation, utilization and relationship between ports in the United Kingdom at the macro level and the behavior and operational characteristics of ships at the micro level was also conducted. XGBoost was shown to perform slightly better and was used as a proof-of-concept algorithm. The XGBoost approach was also shown to be more useful in accurately capturing nonlinear data and improving model performance. The model can be used in simulated port creation, scenario planning and optimization of port operations (Bonham et al., 2018).
Lastly, Alex Noyvirt et al. explored the use of ship movements in the United Kingdom to form indicators. These indicators have the possibility to complement indicators on international trade activity. The indicators are “time-in-port,” which is based on the aggregate time spent by ships in the 10 main UK ports, and “total traffic,” which is based on the number of unique ships entering the 10 main UK ports (Noyvirt et al., 2019). However, the indicators generated from this study were not recommended for use as predictors of gross domestic product (GDP) or other key economic statistics (Noyvirt et al., 2019).
3. Materials and methods
3.1 Data collection
AIS data is provided by exactEarth, accessed via the UNGP at id.officialstatistics.org. This platform can be accessed after obtaining permission or access rights from the UN. The UNGP provides a cloud-based big data computing environment using Amazon Web Service (AWS) and Jupyter Hub. The AIS data consists of static data, dynamic data and voyage-related data that vessels with AIS devices send every few seconds or minutes, depending on the type of data.
In addition, unique to the AIS from the UNGP, the H3 indices of the location data are also provided. The Hexagonal Hierarchical Geospatial Indexing System (H3) is a geospatial indexing system that uses hexagonal grids to group spatial data. With a hexagonal shape, the distance between all neighbors is equal (Uber Technologies, Inc., 2023).
For vessel identification, the AIS data also include the IMO number, which serves as a key identifier for maritime activities. According to the SOLAS (Safety of Life at Sea) regulations, possessing an IMO number is a prerequisite for sailing and selling (Shine Micro Inc, 2024).
The AIS data is collected from vessels that have crossed Indonesian waters from January 1, 2022 to December 31, 2022 along with routes outside Indonesian waters crossed by the vessels. The Indonesian EEZ (Economic Exclusive Zone) is depicted as a polygon between latitudes −13.9421° to 7, as shown in Figure 1.
A map depicting Indonesia's Exclusive Economic Zone (EEZ). The map shows the geographic extent of Indonesia's EEZ, highlighted in light blue. The EEZ is bounded by specific latitudes and longitudes, with the northern boundary around 7.5 degrees north and the southern boundary around 12.5 degrees south. The map includes various islands and landmasses within the EEZ, with areas shaded in brown to indicate land.Indonesian exclusive economic zone
A map depicting Indonesia's Exclusive Economic Zone (EEZ). The map shows the geographic extent of Indonesia's EEZ, highlighted in light blue. The EEZ is bounded by specific latitudes and longitudes, with the northern boundary around 7.5 degrees north and the southern boundary around 12.5 degrees south. The map includes various islands and landmasses within the EEZ, with areas shaded in brown to indicate land.Indonesian exclusive economic zone
Several key variables were selected from the AIS dataset. MMSI and IMO serve as unique vessel identifiers that enable consistent tracking and linkage with ship registry data. The vessel_type, vessel_type_code, flag_country and flag_code variables describe the ship’s function and registration, allowing differentiation of vessel categories and nationality composition involved in port activities.
Navigation-related variables – nav_status, nav_status_code and SOG – indicate vessel movement states such as sailing, anchoring, or mooring, which are crucial for detecting port arrival and departure events. Spatial–temporal positioning is represented by dt_pos_utc (timestamp), longitude and latitude (WGS 84 coordinates), while H3_index_8 provides a hexagonal spatial reference at resolution 8 for identifying vessel presence within port boundaries or AOI. Collectively, these variables enable accurate detection of port visits and estimation of turn-around times, supporting the research objective of modeling vessel traffic and port performance using AIS data.
The UNGP also provides access to ship register data from IHS Markit. The data consists of IMO ship number and detailed information about ship specifications.
In addition to these two data, the list of Indonesian port coordinates was obtained by web scraping the Maritime Safety Information (MSI) website. For validation, official statistical data on the number of vessel visits to Indonesian ports is sourced from BPS. There are 70 ports that appear in both the MSI and BPS datasets, and these common ports are used for the comparison with official statistics. The data sources and preprocessing methods used in this study are illustrated in Figure 2.
The diagram illustrates the data sources, tools, and preprocessing methods used for maritime data analysis. It begins with data storage using Amazon S3, which includes two S3 buckets. Data input is divided into AIS data and IHS data, each containing specific information such as ship identifier, ship voyage information, and ship identifier information. Additional data sources include the World Port Index and Statistics Maritime, which provide ship visit data. The preprocessing stage involves deleting duplicate records, handling values by replacing default, invalid, and missing values, and filtering to eliminate invalid data. Tools used include Jupyter and PySpark. The diagram also specifies valid values for various data fields such as MMSI, IMO, vessel navigation status, vessel type, vessel flag country, latitude, longitude, and vessel movements. The overall structure shows the flow from data storage to data input, followed by preprocessing, and finally the tools used for analysis.Data, tools and preprocessing method
The diagram illustrates the data sources, tools, and preprocessing methods used for maritime data analysis. It begins with data storage using Amazon S3, which includes two S3 buckets. Data input is divided into AIS data and IHS data, each containing specific information such as ship identifier, ship voyage information, and ship identifier information. Additional data sources include the World Port Index and Statistics Maritime, which provide ship visit data. The preprocessing stage involves deleting duplicate records, handling values by replacing default, invalid, and missing values, and filtering to eliminate invalid data. Tools used include Jupyter and PySpark. The diagram also specifies valid values for various data fields such as MMSI, IMO, vessel navigation status, vessel type, vessel flag country, latitude, longitude, and vessel movements. The overall structure shows the flow from data storage to data input, followed by preprocessing, and finally the tools used for analysis.Data, tools and preprocessing method
3.2 Data preprocessing
Like any other data, AIS data also has problems with data quality. It may contain messages that have default values, invalid values, missing values, noise, or outliers. Some of the causes are the loss of AIS device signals and manual inputs for static messages (Asian Development Bank, 2023). For this reason, AIS data needs to go through an appropriate preprocessing stage to address these data quality issues and get data that fits the scope of the research.
The preprocessing stage is described as follows.
Deletion of duplicate messages: Data often contains noise in the form of duplicate data (Emmens et al., 2021). Duplicate records are deleted to retain only unique AIS messages.
Merging AIS and IHS data: The value-handling focuses on addressing inaccuracies in the static MMSI and IMO features, which are often found to be incorrectly recorded (Anuoluwapo, 2023). To improve data quality, the AIS data are merged with the verified IHS registry, allowing inaccurate or missing MMSI and IMO values to be validated and corrected, thereby enhancing the consistency and reliability of vessel identification.
Filtering of invalid and irrelevant feature value: Default values, invalid values, noise or outliers, and missing values that cannot be resolved by merging AIS and IHS data will be handled using a filter process according to the format of each feature (International Telecommunication Union, 2005; Raymond, 2021; Salgado and Oancea, 2017; SINAY Maritime Data Solution, 2022). Filters are also applied in order to obtain data that is relevant to the research conducted.
3.3 Algorithm formation
For surveillance algorithms in the port area, a clear definition of the port area is required. In order to identify the port area, referred to as the Area of Interest (AOI), two approaches are applied: Distance-Based approach and Cluster-Based approach (Asian Development Bank, 2023).
The Distance-Based approach is a rule-based approach that defines a port boundary as an area within a specified distance from a predefined center. Meanwhile, the Cluster-Based approach identifies clusters in AIS messages, around which convex polygons are drawn to delimit the AOI.
The Distance-Based approach is applied for Indonesian port AOIs using a square centered on the port coordinates, where the shortest distance from the center point to the sides of the square is 3.3 km. The Cluster-Based approach is applied for foreign port AOIs using a 22 km square boundary to identify clusters.
The selection of a 3.3 km threshold is supported by the spatial characteristics of major Indonesian ports. For example, Port of Tanjung Priok, the largest and busiest port in Indonesia, has an approximate total area of 1,574 hectares (15.74 km2). A square AOI with a half-side distance of 3.3 km corresponds to a total area of 43.56 km2, which is substantially larger than the physical extent of the port. This indicates that the selected threshold is sufficient to encompass the core port area, including anchorage and maneuvering zones, while still limiting excessive spatial noise.
The 22 km threshold applied to foreign ports is based on established practices in previous studies and institutional guidelines, including those reported by the Asian Development Bank, where larger spatial buffers are used to account for broader anchorage areas, higher traffic density and more complex port geometries in international contexts (Asian Development Bank, 2023).
These parameter choices reflect geographic and operational differences, where Indonesia’s archipelagic characteristics favor relatively compact AOIs, while larger AOIs are more appropriate for foreign ports. Therefore, the selected parameters are considered appropriate for capturing port-related vessel activity while maintaining a balance between spatial coverage and noise reduction.
3.3.1 Algorithm of vessel entry-exit flow at Indonesian Ports
The establishment of the Indonesian port entry-exit flow algorithm consists of several stages, namely, 1) determining the AOIs and Non-AOIs, 2) detecting the position of the vessel and 3) determining the entry-exit flow of the vessel.
The non-AOIs are areas other than the focus area, which will be used to detect the flow of the vessel. They are defined as the area surrounding the AOIs.
To detect the position of the vessel, the H3 indices are used. By comparing the vessel’s H3 index (at resolution 8) from each AIS record with the predefined H3 indices of ports (AOI), the vessel’s position can be classified. If both indices match, the vessel is labeled as in port (AOI); otherwise, it is labeled as out of port (non-AOI).
Once the position of a vessel has been confirmed to be in AOI or Non-AOI, the flow of the vessel is determined. Vessels that are detected to be in Non-AOI first, then AOI after, are classified as vessels entering the port. Conversely, a vessel that is detected to be in AOI first and then Non-AOI afterward is classified as a vessel leaving the port.
To ensure data quality, records with unusually long gaps between consecutive AIS messages are excluded. Specifically, vessel records with an inter-record time difference greater than 72 hours, as well as vessels remaining within a port area for more than 72 hours, are removed from the analysis.
The selection of the 72-hour threshold is supported by operational considerations and empirical observations. In the Indonesian context, port activities – particularly for passenger vessels – tend to occur within relatively short turnaround times. Field observations and discussion with the harbor master of Merak Port indicate that the turnaround time for passenger vessels, from berthing to departure, does not exceed approximately 1.5 hours.
Given this operational evidence, a 72-hour threshold represents a highly conservative upper bound that safely encompasses normal port stay durations while effectively filtering out anomalous records, such as AIS gaps, inactive transmissions or vessels that are not engaged in typical port operations.
Based on these steps, the number of vessels entering and leaving Indonesian ports is obtained. Overall, the stages of the algorithm are illustrated in Figure 3.
A flowchart illustrating the algorithm for determining the number of vessels entering and leaving Indonesian ports. The process starts by importing the required packages and reading port data from a database. It then creates a port bounding box extending 3.3 km from the port coordinates. The flowchart branches into two paths: one for Non-AOI Ports in Indonesia and another for AOI Ports in Indonesia. For Non-AOI Ports, it extracts the k-ring cells from the H3 index of the port. For AOI Ports, it directly matches the vessel's H3 index with the H3 cells of the port's AOI. If a vessel is within the port's AOI, the 'position' column is assigned 'in port'; otherwise, it is assigned 'out port'. The algorithm then filters the 'out port' records to identify valid port visits, requiring at least two 'in port' records between 'out port' records. It further checks whether the record following an 'in port' record corresponds to a valid port and whether the preceding record is an 'out port' record.Flowchart of vessel entry-exit flow algorithm at Indonesian ports
A flowchart illustrating the algorithm for determining the number of vessels entering and leaving Indonesian ports. The process starts by importing the required packages and reading port data from a database. It then creates a port bounding box extending 3.3 km from the port coordinates. The flowchart branches into two paths: one for Non-AOI Ports in Indonesia and another for AOI Ports in Indonesia. For Non-AOI Ports, it extracts the k-ring cells from the H3 index of the port. For AOI Ports, it directly matches the vessel's H3 index with the H3 cells of the port's AOI. If a vessel is within the port's AOI, the 'position' column is assigned 'in port'; otherwise, it is assigned 'out port'. The algorithm then filters the 'out port' records to identify valid port visits, requiring at least two 'in port' records between 'out port' records. It further checks whether the record following an 'in port' record corresponds to a valid port and whether the preceding record is an 'out port' record.Flowchart of vessel entry-exit flow algorithm at Indonesian ports
3.3.2 Algorithm for vessel duration at Indonesian Ports
The duration of a vessel’s stay at the port is determined by analyzing the sequence of AIS messages transmitted while the vessel is within and outside the AOI. Each vessel’s movement is tracked based on its labeled positions – in port when the H3 index of the vessel matches the H3 index of the port, and out of port otherwise. The time spent in port is then calculated by taking the time difference between the first AIS message received when the vessel enters the AOI and the first message received after it leaves the AOI. This difference represents the total duration of stay for a single port call. To obtain a broader view of port activity, the durations of all recorded port stays are aggregated, and both the average and median durations are computed on a monthly basis. This temporal aggregation helps to identify patterns or seasonal variations in vessel traffic and port utilization.
The stages of calculating the vessel’s time in port are illustrated in Figure 4.
The flowchart begins with reading ship flow data of Indonesian ports from a database. The next step involves calculating the difference between the dt_pos_utc record and the next dt_pos_utc record. Following this, the 'in port' record is selected. The time of a record is summed if the record after it has the same port value for each MMSI, indicating the total time of the ship from first detected in port to first detected out of port. This process results in a dataset of vessel duration at Indonesian ports. The mean and median of ship duration at port are then calculated, leading to a dataset of mean and median duration of vessels at Indonesian ports. The flowchart concludes with the end of the process.Flowchart for calculating vessel time at port
The flowchart begins with reading ship flow data of Indonesian ports from a database. The next step involves calculating the difference between the dt_pos_utc record and the next dt_pos_utc record. Following this, the 'in port' record is selected. The time of a record is summed if the record after it has the same port value for each MMSI, indicating the total time of the ship from first detected in port to first detected out of port. This process results in a dataset of vessel duration at Indonesian ports. The mean and median of ship duration at port are then calculated, leading to a dataset of mean and median duration of vessels at Indonesian ports. The flowchart concludes with the end of the process.Flowchart for calculating vessel time at port
3.3.3 Algorithm for detecting Indonesian vessel visits abroad
The algorithm for detecting Indonesian vessel visits in overseas ports is more or less the same as the algorithm for entry-exit flow for Indonesian ports. The difference between the two algorithms is that the ports are foreign ports. Overall, the stages of the formation of the Indonesian overseas visit detection algorithm are contained in the following flowchart Figure 5. Based on these steps, the number of Indonesian vessels entering and leaving the world’s ports is obtained.
The flowchart begins with the import of required packages and the reading of port world data using the WPI website API. It then forms a port bounding box with a distance of 22 km around the port center for Indonesia and extracts k-rings from the H3 index of the port. The process involves matching the H3 index of the ship with AOI of the port and determining if the vessel is within or outside the AOI. The position of the vessel is recorded as 'in port' or 'out port' and filtered accordingly. The flowchart includes decision points to label the vessel's position and filter records based on specific criteria. The final step involves selecting ship status information and determining if the vessel is in or out of the port.Flowchart of the algorithm for detecting Indonesian vessel visits abroad
The flowchart begins with the import of required packages and the reading of port world data using the WPI website API. It then forms a port bounding box with a distance of 22 km around the port center for Indonesia and extracts k-rings from the H3 index of the port. The process involves matching the H3 index of the ship with AOI of the port and determining if the vessel is within or outside the AOI. The position of the vessel is recorded as 'in port' or 'out port' and filtered accordingly. The flowchart includes decision points to label the vessel's position and filter records based on specific criteria. The final step involves selecting ship status information and determining if the vessel is in or out of the port.Flowchart of the algorithm for detecting Indonesian vessel visits abroad
3.4 Algorithm evaluation
For algorithm efficiency evaluation, Big-O notation is used. Big-O notation describes the asymptotic upper bound on the growth of an algorithm’s running time as the input size increases (Ichi.Pro, 2024; Mahrozi and Faisal, 2023).
Suppose and are two functions of a certain subset of the real numbers, then
If the time complexity of an algorithm is , the running time grows at most proportionally to a constant multiple of as the input size increases.
Common complexity classes include O(1), O(log n), O(n), O(n2) and O(nn). An algorithm has O(1) complexity when its execution time remains constant regardless of the input size. O(log n) complexity occurs when the problem size is reduced by a constant factor at each step, such as in binary search. O(n) complexity indicates that the running time grows linearly with the input size. O(n2) complexity typically occurs when the number of operations grows proportionally to the square of the input size, such as in certain nested-loop algorithms.
For algorithm performance evaluation, root mean squared error (RMSE) and mean absolute percentage error (MAPE) are employed to quantify the differences between predicted and observed values. RMSE measures the average magnitude of prediction errors, with greater emphasis on larger errors due to the squaring process (Hodson, 2022). It is defined as follows in Equation (2).
where is the number of observations, is the predicted value at time , and is the corresponding observed value. A lower RMSE indicates better model performance, particularly in minimizing large errors.
In addition to RMSE, MAPE is used to express prediction accuracy in percentage terms, making it easier to interpret across different scales. MAPE represents the average of absolute percentage errors between predicted and observed values (Nabillah and Ranggadara, 2020) and is defined as follows in Equation (3).
where , and are defined as previously. A lower MAPE value indicates higher predictive accuracy, although it may be sensitive to very small observed values.
4. Results and discussion
4.1 Overview of AIS data and preprocessing result
AIS data that had been detected in Indonesian waters throughout 2022, along with other routes outside Indonesian waters crossed, were extracted. The AIS data records amounted to 1,769,530,772 records. The results of the data quality review are as follows.
First, the comparison of AIS data records with unique MMSI and IMO values according to vessel type will be examined. Based on the diagrams in Figure 6, there are some types of vessels that have a number of records with unique IMO less than the number of records with unique MMSI. This can happen because there are vessels that have AIS devices, so they have MMSI numbers, but do not have IMO numbers as vessel identities.
The bar graph compares the number of AIS data records with unique MMSI and IMO values by vessel type in 2022. The x-axis represents the number of records, while the y-axis lists different vessel types. The graph features horizontal bars, with two data series represented by different colors: dark blue for MMSI unique and light blue for IMO unique. The vessel types include Unknown, Cargo, Tanker, Tug, Fishing, Pleasure Craft, Other, Passenger, Towing, Not Available, Reserved, Sailing, WIG, HSC, Dredging, UNAVAILABLE, Military, Pilot, Law Enforcement, Port Tender, Spare, SAR, Diving, Vessel With Anti-Pollution Equipment, Ships Not Party to Armed Conflict, and Medical Transport. Notable trends include a significantly higher number of records for the Unknown category, with MMSI unique at 20,671 and IMO unique at 5,580. Cargo vessels also show a high number of records, with MMSI unique at 7,470 and IMO unique at 8,555. All values are approximated.Number of AIS data records with MMSI and IMO unique by vessel type in 2022
The bar graph compares the number of AIS data records with unique MMSI and IMO values by vessel type in 2022. The x-axis represents the number of records, while the y-axis lists different vessel types. The graph features horizontal bars, with two data series represented by different colors: dark blue for MMSI unique and light blue for IMO unique. The vessel types include Unknown, Cargo, Tanker, Tug, Fishing, Pleasure Craft, Other, Passenger, Towing, Not Available, Reserved, Sailing, WIG, HSC, Dredging, UNAVAILABLE, Military, Pilot, Law Enforcement, Port Tender, Spare, SAR, Diving, Vessel With Anti-Pollution Equipment, Ships Not Party to Armed Conflict, and Medical Transport. Notable trends include a significantly higher number of records for the Unknown category, with MMSI unique at 20,671 and IMO unique at 5,580. Cargo vessels also show a high number of records, with MMSI unique at 7,470 and IMO unique at 8,555. All values are approximated.Number of AIS data records with MMSI and IMO unique by vessel type in 2022
A possible cause for the imbalance in the number of records with a unique IMO and the number of records with a unique MMSI is that some vessels are not required to have an IMO number. Vessels required to have an IMO number have a gross tonnage (GT) of greater than 100 tons.
Then, the proportion of valid, default, invalid and missing values of some variables will be seen. Based on the diagram in Figure 7, there are three features with valid values of less than 99%, namely IMO, navigation status and vessel flag. As much as 5.68% of the overall IMO value is a missing value, while the navigation status has an invalid value of 3.69% of the overall data. The country flag also has some values that are missing, which is around 1.38% of the overall data. This means that further handling of the missing, default and invalid values of IMO features is needed.
A bar graph compares the proportion of valid, default, invalid, and missing record values across different variables. The graph features eight vertical bars, each representing a different variable: IMO, navigation status, vessel flag, vessel type, MMSI, date and time of position in UTC, latitude, and longitude. The horizontal axis lists these variables, while the vertical axis indicates the number of records in percent. Each bar is color-coded to represent valid values in blue, missing values in dark blue, invalid values in orange, and default values in purple. The IMO variable has 5.675% missing values and 94.074% valid values. The navigation status variable has 3.685% invalid values and 94.717% valid values. The vessel flag variable has 1.383% missing values and 98.618% valid values. The vessel type, MMSI, date and time of position in UTC, latitude, and longitude variables all show 100% valid values.Proportion of valid, default, invalid and missing record values by variable
A bar graph compares the proportion of valid, default, invalid, and missing record values across different variables. The graph features eight vertical bars, each representing a different variable: IMO, navigation status, vessel flag, vessel type, MMSI, date and time of position in UTC, latitude, and longitude. The horizontal axis lists these variables, while the vertical axis indicates the number of records in percent. Each bar is color-coded to represent valid values in blue, missing values in dark blue, invalid values in orange, and default values in purple. The IMO variable has 5.675% missing values and 94.074% valid values. The navigation status variable has 3.685% invalid values and 94.717% valid values. The vessel flag variable has 1.383% missing values and 98.618% valid values. The vessel type, MMSI, date and time of position in UTC, latitude, and longitude variables all show 100% valid values.Proportion of valid, default, invalid and missing record values by variable
Finally, the records exhibiting anomalous movements will be examined. Records that are indicated as anomalous movements are records with misaligned navigation status and SOG. So, when a vessel has a navigation status of navigation status of “at anchor” and “moored” the SOG is more than one which should be less than one, and when the vessel has a navigation status of “under way using engine,” “engaged in fishing,” “under way sailing,” “restricted maneuverability,” “not under command,” “aground” the SOG is less than one which should be more than one (Asian Development Bank, 2023).
It can be concluded that although most of the AIS data are of good quality, a small portion still contains inaccuracies that require preprocessing to ensure consistency and reliability. Therefore, preprocessing is necessary as a form of quality assurance for AIS data. Table 1 shows number of records and percentage of reduction for every preprocessing stage. First, duplicate records were removed. This stage left a total of 1,766,897,772 records. This means that 0.15% of records have been reduced compared to the number of AIS records that were detected in Indonesia throughout 2022, which amounted to 1,769,530,772 records. At this stage, there are still features that have default, invalid, or missing values.
Results of AIS data preprocessing
| Data preprocessing stage | Number of records | Reduction (%) |
|---|---|---|
| AIS messages within Indonesian waters, and the foreign routes | 1,769,530,772 | – |
| Deletion of duplicate AIS messages | 1,766,897,772 | 0.1488% |
| AIS message matches IHS Data | 1,696,875,705 | 3.9620% |
| Filter 1: Valid MMSI | 1,696,870,933 | 0.0003% |
| Filter 2: Valid IMO | 1,696,870,933 | 0.0000% |
| Filter 3: Valid and Relevant Navigation Status | 1,634,838,227 | 3.6557% |
| Filter 4: Valid and Relevant Vessel Types | 1,555,568,122 | 4.8488% |
| Filter 5: Valid and Relevant Vessel Countries | 1,535,096,720 | 1.3160% |
| Filter 6: Valid Latitude & Longitude | 1,535,096,720 | 0.0000% |
| Filter 7: Valid dt_pos_utc | 1,535,096,720 | 0.0000% |
| Filter 8: Vessels that are not indicated to have anomalous movements | 1,444,393,573 | 5.9086% |
| Filter 9: MMSI with record ≥10 | 1,444,392,908 | 0.0000% |
| Filter 10: MMSI with sog >3 amounted to ≥20 | 1,443,592,577 | 0.0554% |
| Data preprocessing stage | Number of records | Reduction (%) |
|---|---|---|
| AIS messages within Indonesian waters, and the foreign routes | 1,769,530,772 | – |
| Deletion of duplicate AIS messages | 1,766,897,772 | 0.1488% |
| AIS message matches IHS Data | 1,696,875,705 | 3.9620% |
| Filter 1: Valid MMSI | 1,696,870,933 | 0.0003% |
| Filter 2: Valid IMO | 1,696,870,933 | 0.0000% |
| Filter 3: Valid and Relevant Navigation Status | 1,634,838,227 | 3.6557% |
| Filter 4: Valid and Relevant Vessel Types | 1,555,568,122 | 4.8488% |
| Filter 5: Valid and Relevant Vessel Countries | 1,535,096,720 | 1.3160% |
| Filter 6: Valid Latitude & Longitude | 1,535,096,720 | 0.0000% |
| Filter 7: Valid dt_pos_utc | 1,535,096,720 | 0.0000% |
| Filter 8: Vessels that are not indicated to have anomalous movements | 1,444,393,573 | 5.9086% |
| Filter 9: MMSI with record ≥10 | 1,444,392,908 | 0.0000% |
| Filter 10: MMSI with sog >3 amounted to ≥20 | 1,443,592,577 | 0.0554% |
To handle this, AIS data is merged with IHS data as a form of value-handling of IMO and MMSI features. Data merging is done by matching IMO and MMSI and vessel names with similarities above 0.5, measured using cosine similarity. The records resulting from the merging of AIS data and IHS data totaled 1,696,875,705 records. This means that 3.96% of records have been reduced compared to the number of AIS records resulting from the removal of duplicate records, which amounted to 1,766,897,772 records.
The preprocessing steps resulted in varying levels of data reduction, ranging from negligible reductions to approximately 5.91% of the records from the preceding stage. The largest reductions occurred in Filter 8 (5.91%), Filter 4 (4.85%) and Filter 3 (3.66%). In contrast, Filters 1, 2, 6, 7 and 9 had little or no impact on the number of AIS records. Furthermore, Figure 7 shows that the latitude, longitude and dt_pos_utc features contain no default, invalid or missing values, indicating that these features conform to the predefined data format requirements.
4.2 Algorithm implementation
4.2.1 Algorithm of vessel entry-exit flow at Indonesian Ports
Both approaches, as shown in Figures 8 and 9, result in the number of inbound and outbound vessels with the same pattern throughout 2022, with a fluctuating pattern. That is, there are a very high number of vessels entering and leaving Indonesian ports in certain months and a very low number of vessels entering and leaving Indonesian ports in some other months. The highest is in June and the lowest is in November. This means that vessels visit Indonesian ports the most in June and visit Indonesian ports the least in November.
A line graph showing the number of vessels in and out of Indonesian ports per month in 2022. The x-axis represents the months from January to December, and the y-axis represents the number of vessels, ranging from 20,000 to 50,000. The graph has two lines, one for vessels in and one for vessels out. The data points for each month are as follows: January has 42,866 vessels in and 43,909 vessels out; February has 33,660 vessels in and 32,799 vessels out; March has 36,766 vessels in and 37,789 vessels out; April has 34,190 vessels in and 33,175 vessels out; May has 50,559 vessels in and 49,755 vessels out; June has 55,076 vessels in and 54,137 vessels out; July has 49,790 vessels in and 48,814 vessels out; August has 39,806 vessels in and 38,851 vessels out; September has 44,389 vessels in and 45,301 vessels out; October has 47,851 vessels in and 48,841 vessels out; November has 29,669 vessels in and 28,787 vessels out; December has 43,927 vessels in and 44,585 vessels out.Number of vessels in and out of Indonesian ports per month (distance-based AOI)
A line graph showing the number of vessels in and out of Indonesian ports per month in 2022. The x-axis represents the months from January to December, and the y-axis represents the number of vessels, ranging from 20,000 to 50,000. The graph has two lines, one for vessels in and one for vessels out. The data points for each month are as follows: January has 42,866 vessels in and 43,909 vessels out; February has 33,660 vessels in and 32,799 vessels out; March has 36,766 vessels in and 37,789 vessels out; April has 34,190 vessels in and 33,175 vessels out; May has 50,559 vessels in and 49,755 vessels out; June has 55,076 vessels in and 54,137 vessels out; July has 49,790 vessels in and 48,814 vessels out; August has 39,806 vessels in and 38,851 vessels out; September has 44,389 vessels in and 45,301 vessels out; October has 47,851 vessels in and 48,841 vessels out; November has 29,669 vessels in and 28,787 vessels out; December has 43,927 vessels in and 44,585 vessels out.Number of vessels in and out of Indonesian ports per month (distance-based AOI)
A line graph displays the number of vessels entering and leaving Indonesian ports per month throughout 2022. The horizontal axis represents the months from January to December, and the vertical axis represents the number of vessels, ranging from 20,000 to 50,000. Two data lines are plotted: one for vessels entering (Vessel In) and one for vessels leaving (Vessel Out). Both lines follow a similar fluctuating pattern. The highest number of vessels is observed in June, with approximately 54,352 vessels, while the lowest number is in November, with approximately 28,062 vessels. The trend shows significant peaks in May, June, and December and notable troughs in February, April, and November.Number of vessels in and out of Indonesian ports per month (cluster-based AOI)
A line graph displays the number of vessels entering and leaving Indonesian ports per month throughout 2022. The horizontal axis represents the months from January to December, and the vertical axis represents the number of vessels, ranging from 20,000 to 50,000. Two data lines are plotted: one for vessels entering (Vessel In) and one for vessels leaving (Vessel Out). Both lines follow a similar fluctuating pattern. The highest number of vessels is observed in June, with approximately 54,352 vessels, while the lowest number is in November, with approximately 28,062 vessels. The trend shows significant peaks in May, June, and December and notable troughs in February, April, and November.Number of vessels in and out of Indonesian ports per month (cluster-based AOI)
It can also be seen that there is a difference between the number of incoming vessels and the number of outgoing vessels. This occurs because some records were excluded during preprocessing, as described in the methodology section, particularly those with unusually long-time gaps between AIS messages or vessels staying in port for extended durations.
4.2.2 Algorithm for vessel duration at Indonesian Ports
Both approaches, as shown in Figures 10 and 11, produce vessel durations at Indonesian ports with the same distribution throughout 2022. The duration of the vessel while in Indonesian ports is in the range of 0–20 hours. From the plot of the duration of the vessel while in Indonesian ports, it is also known that there are extreme durations that have been calculated, which are between 20 and 72 hours. This means that there are some vessels that spend quite a long time in Indonesian ports, reaching 72 hours. As explained earlier, vessels that spent more than 72 hours at the port have been eliminated from the data.
The box-and-whisker plot displays the distribution of vessel durations in Indonesian ports. The x-axis is labeled 'All Vessels,' and the y-axis is labeled 'Duration (hour),' ranging from 0 to 70 hours. The plot shows a horizontal box plot. The median duration is approximately 10 hours. The lower quartile (Q1) is at 0 hours, and the upper quartile (Q3) is at around 20 hours. The whiskers extend from 0 to 72 hours, indicating the range of typical vessel durations. There is a notable outlier around 72 hours, suggesting some vessels spend significantly longer in the ports. The plot highlights that most vessels have durations within the 0 to 20-hour range, with extreme durations reaching up to 72 hours. All values are approximated.Vessel duration distribution in Indonesian ports (distance-based AOI)
The box-and-whisker plot displays the distribution of vessel durations in Indonesian ports. The x-axis is labeled 'All Vessels,' and the y-axis is labeled 'Duration (hour),' ranging from 0 to 70 hours. The plot shows a horizontal box plot. The median duration is approximately 10 hours. The lower quartile (Q1) is at 0 hours, and the upper quartile (Q3) is at around 20 hours. The whiskers extend from 0 to 72 hours, indicating the range of typical vessel durations. There is a notable outlier around 72 hours, suggesting some vessels spend significantly longer in the ports. The plot highlights that most vessels have durations within the 0 to 20-hour range, with extreme durations reaching up to 72 hours. All values are approximated.Vessel duration distribution in Indonesian ports (distance-based AOI)
A box-and-whisker plot showing the distribution of vessel durations in Indonesian ports. The plot is vertical with one box plot. The horizontal axis represents the categories labeled 'All Vessels' and the vertical axis represents the duration in hours, ranging from 0 to 70 hours. The box plot indicates that the median duration is around 10 hours. The lower quartile (Q1) is at approximately 0 hours, and the upper quartile (Q3) is around 20 hours. The whiskers extend from 0 to 72 hours, indicating the range of the data. There are no visible outliers. The plot shows that most vessel durations are concentrated between 0 and 20 hours, with some extreme durations reaching up to 72 hours.Vessel duration distribution in Indonesian ports (cluster-based AOI)
A box-and-whisker plot showing the distribution of vessel durations in Indonesian ports. The plot is vertical with one box plot. The horizontal axis represents the categories labeled 'All Vessels' and the vertical axis represents the duration in hours, ranging from 0 to 70 hours. The box plot indicates that the median duration is around 10 hours. The lower quartile (Q1) is at approximately 0 hours, and the upper quartile (Q3) is around 20 hours. The whiskers extend from 0 to 72 hours, indicating the range of the data. There are no visible outliers. The plot shows that most vessel durations are concentrated between 0 and 20 hours, with some extreme durations reaching up to 72 hours.Vessel duration distribution in Indonesian ports (cluster-based AOI)
4.2.3 Algorithm for detecting Indonesian visits abroad
Both approaches, as shown in Figures 12 and 13, result in the number of Indonesian vessels visits abroad with the same pattern throughout 2022, with a fluctuating pattern. That is, there are a very high number of vessels entering and leaving Indonesian ports in certain months and a very low number of vessels entering and leaving Indonesian ports in some other months. The highest was in October and the lowest was in November. This means that Indonesian vessels visit overseas ports the most in October and visit overseas ports the least in November.
The line graph illustrates the number of Indonesian vessel visits overseas per month in 2022. The x-axis represents the months from January to December, while the y-axis represents the number of vessels, ranging from 1,500 to 3,000. The graph includes two data lines: one for vessels entering and one for vessels leaving. The highest number of vessels is observed in October, while the lowest is in November. All values are approximated.Number of Indonesian vessel visits overseas per month (distance-based AOI)
The line graph illustrates the number of Indonesian vessel visits overseas per month in 2022. The x-axis represents the months from January to December, while the y-axis represents the number of vessels, ranging from 1,500 to 3,000. The graph includes two data lines: one for vessels entering and one for vessels leaving. The highest number of vessels is observed in October, while the lowest is in November. All values are approximated.Number of Indonesian vessel visits overseas per month (distance-based AOI)
A line graph titled 'Number of Indonesian vessel visits overseas per month (cluster-based AOI)' displays the number of Indonesian vessels entering and leaving overseas ports throughout 2022. The horizontal axis represents the months from January to December, and the vertical axis represents the number of vessels, ranging from 1,400 to 2,800. Two data lines are plotted: one for vessels entering and one for vessels leaving. Both lines show a fluctuating pattern. The number of vessels entering peaks at 2,757 in October and drops to the lowest point of 1,427 in November. Similarly, the number of vessels leaving peaks at 2,705 in October and drops to the lowest point of 1,458 in November.Number of Indonesian vessel visits overseas per month (cluster-based AOI)
A line graph titled 'Number of Indonesian vessel visits overseas per month (cluster-based AOI)' displays the number of Indonesian vessels entering and leaving overseas ports throughout 2022. The horizontal axis represents the months from January to December, and the vertical axis represents the number of vessels, ranging from 1,400 to 2,800. Two data lines are plotted: one for vessels entering and one for vessels leaving. Both lines show a fluctuating pattern. The number of vessels entering peaks at 2,757 in October and drops to the lowest point of 1,427 in November. Similarly, the number of vessels leaving peaks at 2,705 in October and drops to the lowest point of 1,458 in November.Number of Indonesian vessel visits overseas per month (cluster-based AOI)
4.3 Algorithm efficiency evaluation
The computational complexity of the proposed algorithms is described using Big-O notation. The algorithm for vessel entry–exit flow at Indonesian ports, as well as the algorithm for detecting Indonesian visits abroad, exhibit linear time complexity, denoted as O(n), as their execution involves operations that scale proportionally with the number of input records.
The algorithm for calculating vessel duration at Indonesian ports is relatively efficient, as it does not require iterative comparisons across multiple records. However, in practice, its execution still depends on the size of the input dataset due to data retrieval and transformation processes.
It is important to note that in a distributed computing environment such as Apache Spark, theoretical time complexity provides only a partial view of performance. Actual execution time is influenced by factors such as data partitioning, cluster configuration, memory usage and input/output operations. In this study, the evaluation focuses on estimation accuracy, while practical performance metrics such as runtime and scalability are not explicitly assessed and are recommended for future work.
4.4 Algorithm performance evaluation
The performance of the algorithm is evaluated by calculating RMSE and MAPE. This evaluation is only carried out on the Vessel Entry-Exit Flow Algorithm at Indonesian ports due to limitations on official statistical data sources. Table 2 shows the calculation results.
Algorithm performance evaluation on some Indonesian ports
| Ports | Distance-based AOI | Cluster-based AOI | ||
|---|---|---|---|---|
| RMSE | MAPE | RMSE | MAPE | |
| Banten | 1603.97 | 133.67 | 4895.37 | 412.95 |
| Pontianak | 191.17 | 74.59 | 217.19 | 89.72 |
| Cirebon | 148.14 | 91.22 | 142.33 | 87.80 |
| Amamapare | 83.78 | 400.92 | 127.39 | 612.01 |
| Teluk Bayur | 83.32 | 52.07 | 82.77 | 51.65 |
| Benoa | 70.11 | 47.04 | 70.45 | 53.25 |
| Poso | 11.41 | 70.30 | 13.41 | 85.87 |
| All Ports | 8624.30 | 42.28 | 8963.52 | 43.94 |
| Ports | Distance-based AOI | Cluster-based AOI | ||
|---|---|---|---|---|
| RMSE | MAPE | RMSE | MAPE | |
| Banten | 1603.97 | 133.67 | 4895.37 | 412.95 |
| Pontianak | 191.17 | 74.59 | 217.19 | 89.72 |
| Cirebon | 148.14 | 91.22 | 142.33 | 87.80 |
| Amamapare | 83.78 | 400.92 | 127.39 | 612.01 |
| Teluk Bayur | 83.32 | 52.07 | 82.77 | 51.65 |
| Benoa | 70.11 | 47.04 | 70.45 | 53.25 |
| Poso | 11.41 | 70.30 | 13.41 | 85.87 |
| All Ports | 8624.30 | 42.28 | 8963.52 | 43.94 |
Based on the RMSE and MAPE results, the algorithm using the Distance-Based AOI provides a slightly better estimation of the number of vessels visiting Indonesian ports compared to the Cluster-Based AOI approach. However, the relatively high MAPE values across most ports – particularly exceeding 40% on average – indicate that the estimation accuracy remains limited.
These limitations are primarily associated with the delineation of the AOI. The use of simplified AOI geometries, such as fixed-size square boundaries, may not fully capture the actual spatial extent and operational complexity of port areas, including irregular shapes, anchorage zones and vessel maneuvering patterns. As a result, some vessel movements may be misclassified, either being excluded from or incorrectly included in the AOI.
In addition, the performance evaluation is currently limited to vessel entry-exit counts and does not yet incorporate vessel duration or overseas visit identification algorithms, which may further influence the overall accuracy.
Therefore, while the proposed approach demonstrates initial potential, further refinement of AOI definitions and the integration of additional movement-based indicators are required to improve robustness, particularly if the method is to be considered for official statistical applications.
In addition to calculating RMSE and MAPE for vessel visit estimates across several Indonesian ports, a comparison of vessel visit counts at Poso Port is also presented using a line chart, as shown in Figure 14. The comparison indicates that discrepancies remain between the estimates derived from the Distance-Based AOI algorithm and the official statistics reported by BPS Statistics Indonesia.
A bar graph compares the number of vessels at Poso Port across different months. The horizontal axis represents the months from January to December, and the vertical axis represents the number of vessels, ranging from 0 to 25. The graph includes three data series: grey bars representing the difference, a blue line representing BPS Data, and an orange line representing Prediction Data. The grey bars show the difference in vessel counts for each month. The blue line indicates the official statistics reported by BPS Statistics Indonesia, while the orange line shows the estimates derived from the Distance-Based AOI algorithm. Notable trends include a peak in vessel counts in December for both BPS Data and Prediction Data, with the blue line showing higher values overall compared to the orange line. The grey bars vary in height, indicating the discrepancies between the two data series each month.Comparison of the number of visits at Poso port according to BPS and calculation results using the distance-based AOI algorithm
A bar graph compares the number of vessels at Poso Port across different months. The horizontal axis represents the months from January to December, and the vertical axis represents the number of vessels, ranging from 0 to 25. The graph includes three data series: grey bars representing the difference, a blue line representing BPS Data, and an orange line representing Prediction Data. The grey bars show the difference in vessel counts for each month. The blue line indicates the official statistics reported by BPS Statistics Indonesia, while the orange line shows the estimates derived from the Distance-Based AOI algorithm. Notable trends include a peak in vessel counts in December for both BPS Data and Prediction Data, with the blue line showing higher values overall compared to the orange line. The grey bars vary in height, indicating the discrepancies between the two data series each month.Comparison of the number of visits at Poso port according to BPS and calculation results using the distance-based AOI algorithm
These differences are not primarily driven by vessel type classification, as consistent vessel categories have been applied in both datasets. However, they may arise from inherent limitations in AIS data. AIS coverage is typically biased toward larger vessels, as smaller vessels are not always equipped with AIS transponders or may not consistently transmit signals. This can lead to underrepresentation of certain vessel activities in AIS-based estimates.
In addition, AIS data may be affected by signal gaps, inactive transponders, or positional inaccuracies, which can result in undercounting or misidentification of vessel movements. Differences in the operational definition of a “port call” – such as AIS-based entry-exit detection versus administratively recorded port visits – may further contribute to the observed discrepancies.
Therefore, the variation between AIS-derived estimates and official statistics should be interpreted with caution, as it reflects both data limitations and differences in measurement approaches rather than solely model performance.
Despite these limitations, AIS-derived indicators related to maritime activity – such as port calls and changes in vessel draft – still demonstrate potential for estimating and forecasting international trade dynamics across regional economies when compared with official statistics. Furthermore, the availability of near real-time AIS data can support more timely analysis and policy intervention in areas such as port infrastructure planning, shipping emissions monitoring and the assessment of impacts from climate change and natural hazard–induced disasters (Kim et al., 2023).
5. Conclusion
Based on the results of the research and discussion that have been presented, the following conclusions can be drawn from this study. Several algorithms are formed from AIS data, namely the detection of vessel inflows and outflows at Indonesian ports, the calculation of vessel duration at Indonesian ports and the detection of Indonesian visits abroad.
Algorithms formed from AIS data can be used as an alternative to sea transportation data, such as the number of domestic and foreign vessel visits to Indonesian ports, the duration of vessels at Indonesian ports and the number of Indonesian vessel visits to foreign ports.
Distance-Based and Cluster-Based approaches were used to construct the ports’ AOI. Overall, the Distance-Based AOI approach performs better in estimating the number of domestic and overseas vessel visits to Indonesian ports. However, several ports show improved results when using the Cluster-Based AOI. The Distance-Based AOI generally yields lower overall error values for the total vessel visits across 70 Indonesian ports, while the Cluster-Based AOI produces smaller errors only for a limited number of ports.
However, the AOI formed by the two approaches in this study still cannot define the port area well. One result is the formation of overlapping AOIs between two neighboring ports. The use of other port AOI approach methods, such as Manual AOI, can be considered for future research provided that the port area data is known. In addition, this study only uses ports whose characteristics are sourced from the World Port Index (WPI), namely 123 ports in Indonesia and 3,685 ports abroad.
Author contributions: credit
Ladisa Busaina handled data curation, formal analysis, methodology, visualization and the writing of the original draft. Dewi Krismawati was responsible for the conceptualization of the research. Markie Muryawan contributed to the supervision and reviewed the final draft. Cherryl Chico contributed to the review of the final draft. Setia Pramana contributed to the supervision, investigation, formal analysis of the study and reviewed the final draft.
Financial support from Politeknik Statistika STIS and BPS Statistics Indonesia is gratefully acknowledged. Appreciation is also extended to the AIS Task Team at the United Nations for their invaluable technical guidance, insightful suggestions and intellectual support throughout the course of this research. Finally, the AIS data that underpins this study was provided by the United Nations Statistics Division through the UN Global Platform.

