Supply trend with market rates¶
This is an example combining functionality from our Supply and Market Rates APIs. The aim of the example is to plot a supply trend with superimposed market rates, in order to get a holistic view of market behaviour during a specific period. It then compares the vessels of two days.
Run this example in Colab¶
Setup¶
Install the Signal Ocean SDK:
!pip install signal-ocean
Import required dependencies:
from datetime import date, timedelta
import pandas as pd
import matplotlib.pyplot as plt
from signal_ocean import Connection
from signal_ocean.geos import GeosAPI
from signal_ocean.market_rates import MarketRatesAPI, CargoId
from signal_ocean.supply import (
AisTrackingFilter,
AvailabilityState,
CommercialAvailabilityFilter,
EtaConfiguration,
IncludeExcludeFilter,
MarketDeployment,
MarketStatus,
MinMaxRange,
SupplyAPI,
SupplyFilter,
VesselSubclass,
)
from signal_ocean.vessels import VesselsAPI
Get your personal Signal Ocean API subscription key (acquired here) and use it to create a Connection. Your key needs access to the Supply API for the vessel class that you query.
signal_ocean_api_key = "" # replace with your subscription key
connection = Connection(signal_ocean_api_key)
Create instances of APIs used throughout this notebook:
supply_api = SupplyAPI(connection)
market_rate_api = MarketRatesAPI(connection)
geos_api = GeosAPI(connection)
vessels_api = VesselsAPI(connection)
Parametrization¶
In order to plot a supply trend with the market rates, we need to specify the following parameters for our queries:
vessel_class_name- the class of queried vessels.load_port_name- the loading port.days_back- the number of days the supply trend should reach back, starting from the current date.laycan_end_in_days- the maximum estimated time of arrival for available vessels to reach the loading port.route_description- the route of interest with available market rates.
The supply filters below also select the vessels' push status, market deployment, commercial status, subclass, and how many days since the vessel has transmitted its AIS data.
Commercial availability history in the Supply API starts on 29 January 2026, so the look-back starts on that day at the earliest.
vessel_class_name = "Aframax"
load_port_name = "Ceyhan"
days_back = 90
laycan_end_in_days = 10
route_description = "Afra - Med/Med"
today = date.today()
start_date = max(date(2026, 1, 29), today - timedelta(days=days_back))
end_date = today - timedelta(days=1)
For more information, see the Supply and Market Rate API sections.
Retrieve the supply trend¶
The Vessels API gives the vessel class id for the market rates, and the Geos API gives the load port id.
vessel_class = next(
c for c in vessels_api.get_vessel_classes()
if c.name == vessel_class_name and c.vessel_type_id == 1
)
load_port = next(p for p in geos_api.get_ports() if p.port_name == load_port_name)
vessel_class.id, load_port.port_id
(86, 3812)
The ETA configuration selects the vessels that can reach the load port within laycan_end_in_days.
supply_filter = SupplyFilter(
vessel_class=vessel_class_name,
vessel_subclass=[VesselSubclass.CRUDE],
commercial_availability=CommercialAvailabilityFilter(
availability_state=[
AvailabilityState.AVAILABLE,
AvailabilityState.ON_SUBS,
AvailabilityState.FAILED,
AvailabilityState.CANCELLED,
],
market_status=IncludeExcludeFilter(
values=[MarketStatus.POSS_PUSHED, MarketStatus.PUSHED]
),
market_deployment=[MarketDeployment.RELET, MarketDeployment.SPOT],
),
ais_tracking=AisTrackingFilter(days_since_latest_ais=5),
eta_configuration=[
EtaConfiguration(
id="load_port",
basis_port_id=load_port.port_id,
eta_relative_offset=MinMaxRange(min=0, max=laycan_end_in_days),
)
],
)
supply_trend = supply_api.get_supply_trend(
start_date, end_date, filters=supply_filter
).to_data_frame()
supply_trend
| supply | |
|---|---|
| date | |
| 2026-08-13 | 213 |
| 2026-08-14 | 218 |
| 2026-08-15 | 204 |
| 2026-08-16 | 209 |
| 2026-08-17 | 229 |
| ... | ... |
| 2026-11-06 | 249 |
| 2026-11-07 | 247 |
| 2026-11-08 | 241 |
| 2026-11-09 | 259 |
| 2026-11-10 | 246 |
90 rows × 1 columns
Get daily market rates for the route¶
We'll need a helper function to find our desired route for the market rates:
def return_selected_route(vessel_class, route_description):
vessel_routes = market_rate_api.get_routes(vessel_class_id=vessel_class.id)
for i, _ in enumerate(vessel_routes):
if vessel_routes[i].description == route_description:
break
return vessel_routes[i]
Which we can use to find the route object returned from the Market Rates API:
market_rate_route = return_selected_route(vessel_class, route_description)
And use it to query for market rates:
market_rates = market_rate_api.get_market_rates(
start_date,
route_id=market_rate_route.id,
vessel_class_id=vessel_class.id,
end_date=end_date,
cargo_id=CargoId(market_rate_route.cargo_id)
)
market_rates = pd.DataFrame([vars(vr) for vr in market_rates])
market_rates["rate_date"] = pd.to_datetime(market_rates["rate_date"])
market_rates = market_rates.set_index("rate_date")
market_rates
| route_id | rate_value | unit | vessel_class_id | deprecated_to | |
|---|---|---|---|---|---|
| rate_date | |||||
| 2026-08-13 00:00:00+00:00 | R1 | 210.0 | WS | 86 | None |
| 2026-08-14 00:00:00+00:00 | R1 | 240.0 | WS | 86 | None |
| 2026-08-15 00:00:00+00:00 | R1 | 240.0 | WS | 86 | None |
| 2026-08-16 00:00:00+00:00 | R1 | 240.0 | WS | 86 | None |
| 2026-08-17 00:00:00+00:00 | R1 | 240.0 | WS | 86 | None |
| ... | ... | ... | ... | ... | ... |
| 2026-11-06 00:00:00+00:00 | R1 | 305.0 | WS | 86 | None |
| 2026-11-07 00:00:00+00:00 | R1 | 305.0 | WS | 86 | None |
| 2026-11-08 00:00:00+00:00 | R1 | 305.0 | WS | 86 | None |
| 2026-11-09 00:00:00+00:00 | R1 | 270.0 | WS | 86 | None |
| 2026-11-10 00:00:00+00:00 | R1 | 270.0 | WS | 86 | None |
90 rows × 5 columns
Plot the daily supply trend with market rates¶
plt.style.use("seaborn-v0_8")
fig, axs = plt.subplots(figsize=(15, 6))
supply_counts = supply_trend["supply"]
supply_counts.index = supply_counts.index.strftime("%d %b %y")
# Left axis (Supply plot)
supply_plot = supply_counts.plot(ax=axs, color="#3086EF", marker="o")
supply_plot.set_ylabel(
"Vessel count", color=plt.gca().lines[-1].get_color(), fontsize=14
)
supply_plot.set_ylim(ymin=0)
# Right axis (Market rate plot)
market_rates.index = market_rates.index.strftime("%d %b %y")
mr_plot = market_rates.plot(
ax=axs, y="rate_value", secondary_y=True, color="#F06C6E", marker="d"
)
mr_plot.set_ylabel(
"Market Rates (WS)", color=plt.gca().lines[-1].get_color(), fontsize=14
)
axs.set_xlim(0, len(supply_counts) - 1)
axs.set_xlabel("")
axs.get_legend().remove()
Perform a point-to-point comparison¶
Here's an example of a workflow to compare two different points in time. get_historical_supply returns the vessels of one day. Each API key can make 5 of these calls per day.
Specify the dates to compare:
point_a = today - timedelta(days=1)
point_b = today - timedelta(days=5)
vessels_in_a = supply_api.get_historical_supply(
point_a, filters=supply_filter
).to_data_frame().set_index("imo")
vessels_in_b = supply_api.get_historical_supply(
point_b, filters=supply_filter
).to_data_frame().set_index("imo")
print(f"{len(vessels_in_a)} vessels on {point_a}, {len(vessels_in_b)} vessels on {point_b}")
54 vessels on 2026-11-10, 53 vessels on 2026-11-06
Intersection of Vessel IMOs¶
intersection = pd.merge(
vessels_in_a.add_suffix("_IN_A"),
vessels_in_b.add_suffix("_IN_B"),
how="inner",
on="imo",
)
intersection
| day_IN_A | vessel_class_id_IN_A | vessel_class_IN_A | open_location_IN_A | open_location_taxonomy_IN_A | open_location_geo_id_IN_A | open_location_taxonomy_id_IN_A | open_date_from_IN_A | open_date_to_IN_A | availability_state_IN_A | ... | ais_destination_taxonomy_IN_B | ais_destination_geo_id_IN_B | ais_destination_taxonomy_id_IN_B | eta_to_ais_destination_IN_B | miles_to_ais_destination_IN_B | delays_to_ais_destination_IN_B | eta_load_port_IN_B | eta_distance_load_port_IN_B | eta_basis_port_id_load_port_IN_B | eta_canals_load_port_IN_B | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| imo | |||||||||||||||||||||
| 9693056 | 2026-11-10 12:00:00 | 86 | Aframax | East Mediterranean | Level0 | 24737 | 4 | 2026-11-10 11:30:09.000 | 2026-11-10 11:30:09.000 | Available | ... | Port | 3370.0 | 2.0 | 2026-11-06 12:00:00 | 8.37 | 0.0 | 2026-11-11 02:00:00 | 478.67 | 3812 | [Suez] |
| 9690822 | 2026-11-10 12:00:00 | 86 | Aframax | East Mediterranean | Level0 | 24737 | 4 | 2026-11-10 11:28:21.000 | 2026-11-10 11:28:21.000 | Available | ... | Port | 3473.0 | 2.0 | 2026-11-06 11:00:00 | 2.62 | 0.0 | 2026-11-11 10:00:00 | 681.42 | 3812 | [] |
| 9528031 | 2026-11-10 12:00:00 | 86 | Aframax | Augusta | Port | 3547 | 2 | 2026-11-14 04:52:33.037 | 2026-11-14 04:52:33.037 | Available | ... | Port | 3547.0 | 2.0 | 2026-11-11 16:00:00 | 1501.03 | 0.0 | 2026-11-14 10:00:00 | 1036.47 | 3812 | [] |
| 9831309 | 2026-11-10 12:00:00 | 86 | Aframax | West Mediterranean | Level0 | 24712 | 4 | 2026-11-10 11:28:39.000 | 2026-11-10 11:28:39.000 | OnSubs | ... | Port | 7345.0 | 2.0 | 2026-11-09 05:00:00 | 790.65 | 0.0 | 2026-11-16 06:00:00 | 2824.29 | 3812 | [] |
| 9516959 | 2026-11-10 12:00:00 | 86 | Aframax | Central Mediterranean | Level0 | 24738 | 4 | 2026-11-10 11:21:06.000 | 2026-11-10 11:21:06.000 | Available | ... | Port | 3565.0 | 2.0 | 2026-11-06 12:00:00 | 4.29 | 0.0 | 2026-11-11 22:00:00 | 1410.36 | 3812 | [] |
| 9825477 | 2026-11-10 12:00:00 | 86 | Aframax | West Mediterranean | Level0 | 24712 | 4 | 2026-11-10 11:19:49.000 | 2026-11-10 11:19:49.000 | OnSubs | ... | Port | 3554.0 | 2.0 | 2026-11-06 11:00:00 | 0.00 | 0.0 | 2026-11-13 09:00:00 | 1546.58 | 3812 | [] |
| 1055571 | 2026-11-10 12:00:00 | 86 | Aframax | Central Mediterranean | Level0 | 24738 | 4 | 2026-11-10 11:27:22.000 | 2026-11-10 11:27:22.000 | Available | ... | Port | 3565.0 | 2.0 | 2026-11-06 12:00:00 | 4.29 | 0.0 | 2026-11-11 08:00:00 | 1404.48 | 3812 | [] |
| 1053755 | 2026-11-10 12:00:00 | 86 | Aframax | Tutunciftlik | Port | 6442 | 2 | 2026-11-11 23:59:59.000 | 2026-11-11 23:59:59.000 | OnSubs | ... | Port | 6442.0 | 2.0 | 2026-11-09 16:00:00 | 205.23 | 60.0 | 2026-11-15 01:00:00 | 901.27 | 3812 | [Canakkale] |
| 9339337 | 2026-11-10 12:00:00 | 86 | Aframax | West Mediterranean | Level0 | 24712 | 4 | 2026-11-10 11:24:21.000 | 2026-11-10 11:24:21.000 | Available | ... | Level1 | 25008.0 | 5.0 | NaT | NaN | NaN | 2026-11-08 00:00:00 | 440.75 | 3812 | [] |
| 9338917 | 2026-11-10 12:00:00 | 86 | Aframax | East Mediterranean | Level0 | 24737 | 4 | 2026-11-10 11:28:23.000 | 2026-11-10 11:28:23.000 | Available | ... | Port | 7385.0 | 2.0 | 2026-11-06 11:00:00 | 2.50 | 0.0 | 2026-11-08 19:00:00 | 667.39 | 3812 | [] |
| 9337391 | 2026-11-10 12:00:00 | 86 | Aframax | West Mediterranean | Level0 | 24712 | 4 | 2026-11-10 11:23:59.000 | 2026-11-10 11:23:59.000 | Available | ... | Port | 3554.0 | 2.0 | 2026-11-06 12:00:00 | 3.24 | 0.0 | 2026-11-16 22:00:00 | 1546.58 | 3812 | [] |
| 9336397 | 2026-11-10 12:00:00 | 86 | Aframax | Fos | Port | 7348 | 2 | 2026-11-13 23:59:59.000 | 2026-11-13 23:59:59.000 | Available | ... | Port | 7348.0 | 2.0 | 2026-11-06 12:00:00 | 9.54 | 0.0 | 2026-11-13 21:00:00 | 1686.89 | 3812 | [] |
| 9960980 | 2026-11-10 12:00:00 | 86 | Aframax | Iberian Atlantic Coast | Level0 | 24709 | 4 | 2026-11-10 11:21:36.000 | 2026-11-10 11:21:36.000 | Available | ... | Port | 3804.0 | 2.0 | 2026-11-06 11:00:00 | 0.00 | 0.0 | 2026-11-12 04:00:00 | 1296.79 | 3812 | [] |
| 9960978 | 2026-11-10 12:00:00 | 86 | Aframax | Red Sea | Level0 | 24778 | 4 | 2026-11-10 11:23:54.000 | 2026-11-10 11:23:54.000 | Available | ... | Level0 | 24778.0 | 4.0 | 2026-11-05 21:00:00 | 104.54 | 0.0 | 2026-11-12 20:00:00 | 1103.92 | 3812 | [Suez] |
| 9802164 | 2026-11-10 12:00:00 | 86 | Aframax | East Mediterranean | Level0 | 24737 | 4 | 2026-11-10 11:29:32.000 | 2026-11-10 11:29:32.000 | OnSubs | ... | Port | 3641.0 | 2.0 | 2026-11-06 13:00:00 | 22.83 | 0.0 | 2026-11-10 03:00:00 | 1048.94 | 3812 | [] |
| 9946702 | 2026-11-10 12:00:00 | 86 | Aframax | East Mediterranean | Level0 | 24737 | 4 | 2026-11-18 08:35:50.808 | 2026-11-18 08:35:50.808 | Available | ... | NaN | NaN | NaN | NaT | NaN | NaN | 2026-11-08 23:00:00 | 712.40 | 3812 | [] |
| 9787170 | 2026-11-10 12:00:00 | 86 | Aframax | Sea of Marmara | Level0 | 24584 | 4 | 2026-11-10 11:27:18.000 | 2026-11-10 11:27:18.000 | Available | ... | NaN | NaN | NaN | NaT | NaN | NaN | 2026-11-09 05:00:00 | 794.94 | 3812 | [Canakkale] |
| 1025590 | 2026-11-10 12:00:00 | 86 | Aframax | Trieste | Port | 3565 | 2 | 2026-11-14 23:59:59.000 | 2026-11-14 23:59:59.000 | OnSubs | ... | Port | 3565.0 | 2.0 | 2026-11-08 16:00:00 | 629.05 | 0.0 | 2026-11-13 02:00:00 | 665.66 | 3812 | [] |
| 1023920 | 2026-11-10 12:00:00 | 86 | Aframax | West Mediterranean | Level0 | 24712 | 4 | 2026-11-10 11:21:27.000 | 2026-11-10 11:21:27.000 | OnSubs | ... | Port | 7348.0 | 2.0 | 2026-11-06 12:00:00 | 7.85 | 0.0 | 2026-11-14 21:00:00 | 1686.89 | 3812 | [] |
| 1022457 | 2026-11-10 12:00:00 | 86 | Aframax | Iberian Atlantic Coast | Level0 | 24709 | 4 | 2026-11-10 10:33:57.000 | 2026-11-10 10:33:57.000 | Available | ... | NaN | NaN | NaN | NaT | NaN | NaN | 2026-11-16 04:00:00 | 2798.98 | 3812 | [] |
| 9777931 | 2026-11-10 12:00:00 | 86 | Aframax | North West Africa | Level0 | 25007 | 4 | 2026-11-10 11:30:22.000 | 2026-11-10 11:30:22.000 | Available | ... | Port | 3379.0 | 2.0 | 2026-11-06 11:00:00 | 1.89 | 0.0 | 2026-11-14 02:00:00 | 2042.88 | 3812 | [] |
| 9776755 | 2026-11-10 12:00:00 | 86 | Aframax | Sea of Marmara | Level0 | 24584 | 4 | 2026-11-10 11:27:28.000 | 2026-11-10 11:27:28.000 | Available | ... | Port | 7385.0 | 2.0 | 2026-11-06 11:00:00 | 1.68 | 0.0 | 2026-11-08 19:00:00 | 667.16 | 3812 | [] |
| 9930624 | 2026-11-10 12:00:00 | 86 | Aframax | Fos | Port | 7348 | 2 | 2026-11-11 12:42:32.900 | 2026-11-11 12:42:32.900 | Available | ... | Port | 7348.0 | 2.0 | 2026-11-06 12:00:00 | 7.85 | 0.0 | 2026-11-12 21:00:00 | 1686.89 | 3812 | [] |
| 9298650 | 2026-11-10 12:00:00 | 86 | Aframax | Jeddah | Port | 3773 | 2 | 2026-11-12 00:00:00.000 | 2026-11-12 00:00:00.000 | Available | ... | NaN | NaN | NaN | NaT | NaN | NaN | 2026-11-12 08:00:00 | 963.51 | 3812 | [Suez] |
| 9920497 | 2026-11-10 12:00:00 | 86 | Aframax | Savona | Port | 3563 | 2 | 2026-11-11 23:59:59.000 | 2026-11-11 23:59:59.000 | Available | ... | Port | 3563.0 | 2.0 | 2026-11-06 12:00:00 | 14.32 | 0.0 | 2026-11-12 09:00:00 | 1546.58 | 3812 | [] |
| 9752797 | 2026-11-10 12:00:00 | 86 | Aframax | West Mediterranean | Level0 | 24712 | 4 | 2026-11-10 11:30:44.000 | 2026-11-10 11:30:44.000 | Available | ... | NaN | NaN | NaN | NaT | NaN | NaN | 2026-11-13 08:00:00 | 1974.27 | 3812 | [] |
| 9749556 | 2026-11-10 12:00:00 | 86 | Aframax | Milazzo | Port | 3557 | 2 | 2026-11-12 00:00:00.000 | 2026-11-12 00:00:00.000 | Available | ... | Port | 3557.0 | 2.0 | 2026-11-06 12:00:00 | 5.72 | 0.0 | 2026-11-11 18:00:00 | 1079.50 | 3812 | [] |
| 9420617 | 2026-11-10 12:00:00 | 86 | Aframax | Sarroch | Port | 3562 | 2 | 2026-11-10 23:59:59.000 | 2026-11-10 23:59:59.000 | Available | ... | NaN | NaN | NaN | NaT | NaN | NaN | 2026-11-11 02:00:00 | 1333.20 | 3812 | [] |
| 9730945 | 2026-11-10 12:00:00 | 86 | Aframax | Genoa | Port | 3554 | 2 | 2026-11-11 18:22:50.062 | 2026-11-11 18:22:50.062 | OnSubs | ... | Port | 3554.0 | 2.0 | 2026-11-06 12:00:00 | 4.18 | 0.0 | 2026-11-16 09:00:00 | 1546.58 | 3812 | [] |
| 9572264 | 2026-11-10 12:00:00 | 86 | Aframax | Trieste | Port | 3565 | 2 | 2026-11-10 23:59:59.000 | 2026-11-10 23:59:59.000 | OnSubs | ... | NaN | NaN | NaN | NaT | NaN | NaN | 2026-11-16 09:00:00 | 1410.36 | 3812 | [] |
| 9395329 | 2026-11-10 12:00:00 | 86 | Aframax | Midia | Port | 7388 | 2 | 2026-11-11 05:20:48.324 | 2026-11-11 05:20:48.324 | Available | ... | NaN | NaN | NaN | NaT | NaN | NaN | 2026-11-14 22:00:00 | 1318.96 | 3812 | [Canakkale, Bosphorus] |
31 rows × 118 columns
Difference between vessel IMOs in relation to point A¶
vessels_in_a_but_not_in_b = (
vessels_in_a.add_suffix("_IN_A")
.merge(
vessels_in_b.add_suffix("_IN_B"), indicator=True, how="left", on="imo"
)
.loc[lambda x: x["_merge"] != "both"]
)
vessels_in_a_but_not_in_b
| day_IN_A | vessel_class_id_IN_A | vessel_class_IN_A | open_location_IN_A | open_location_taxonomy_IN_A | open_location_geo_id_IN_A | open_location_taxonomy_id_IN_A | open_date_from_IN_A | open_date_to_IN_A | availability_state_IN_A | ... | ais_destination_geo_id_IN_B | ais_destination_taxonomy_id_IN_B | eta_to_ais_destination_IN_B | miles_to_ais_destination_IN_B | delays_to_ais_destination_IN_B | eta_load_port_IN_B | eta_distance_load_port_IN_B | eta_basis_port_id_load_port_IN_B | eta_canals_load_port_IN_B | _merge | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| imo | |||||||||||||||||||||
| 1093432 | 2026-11-10 12:00:00 | 86 | Aframax | Port Said | Port | 7281 | 2 | 2026-11-12 23:59:59.000 | 2026-11-12 23:59:59.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9694658 | 2026-11-10 12:00:00 | 86 | Aframax | Port Said | Port | 7281 | 2 | 2026-11-16 22:25:34.389 | 2026-11-16 22:25:34.389 | OnSubs | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9537927 | 2026-11-10 12:00:00 | 86 | Aframax | Black Sea | Level0 | 24583 | 4 | 2026-11-10 11:21:31.000 | 2026-11-10 11:21:31.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9693068 | 2026-11-10 12:00:00 | 86 | Aframax | Sarroch | Port | 3562 | 2 | 2026-11-14 03:54:41.661 | 2026-11-14 03:54:41.661 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9692478 | 2026-11-10 12:00:00 | 86 | Aframax | Tutunciftlik | Port | 6442 | 2 | 2026-11-12 23:59:59.000 | 2026-11-12 23:59:59.000 | OnSubs | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9527855 | 2026-11-10 12:00:00 | 86 | Aframax | Iberian Atlantic Coast | Level0 | 24709 | 4 | 2026-11-10 11:24:54.000 | 2026-11-10 11:24:54.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9345441 | 2026-11-10 12:00:00 | 86 | Aframax | Marsa El Hamra | Port | 3373 | 2 | 2026-11-13 13:17:33.581 | 2026-11-13 13:17:33.581 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9801988 | 2026-11-10 12:00:00 | 86 | Aframax | Piraeus | Port | 7385 | 2 | 2026-11-15 02:00:53.236 | 2026-11-15 02:00:53.236 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9329409 | 2026-11-10 12:00:00 | 86 | Aframax | Agioi Theodoroi | Port | 3469 | 2 | 2026-11-13 19:29:33.042 | 2026-11-13 19:29:33.042 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9796743 | 2026-11-10 12:00:00 | 86 | Aframax | Genoa | Port | 3554 | 2 | 2026-11-15 14:04:46.096 | 2026-11-15 14:04:46.096 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9787168 | 2026-11-10 12:00:00 | 86 | Aframax | Trieste | Port | 3565 | 2 | 2026-11-11 23:59:59.000 | 2026-11-11 23:59:59.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9473066 | 2026-11-10 12:00:00 | 86 | Aframax | Trieste | Port | 3565 | 2 | 2026-11-15 02:04:59.929 | 2026-11-15 02:04:59.929 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 1024986 | 2026-11-10 12:00:00 | 86 | Aframax | Suez | Port | 3376 | 2 | 2026-11-09 11:09:57.808 | 2026-11-09 11:09:57.808 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9783904 | 2026-11-10 12:00:00 | 86 | Aframax | Red Sea | Level0 | 24778 | 4 | 2026-11-10 11:30:05.000 | 2026-11-10 11:30:05.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9773923 | 2026-11-10 12:00:00 | 86 | Aframax | Arabian Gulf | Level0 | 24777 | 4 | 2026-11-10 11:29:56.000 | 2026-11-10 11:29:56.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9457608 | 2026-11-10 12:00:00 | 86 | Aframax | Algeciras | Port | 3379 | 2 | 2026-11-11 10:09:09.642 | 2026-11-11 10:09:09.642 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9453030 | 2026-11-10 12:00:00 | 86 | Aframax | Sea of Marmara | Level0 | 24584 | 4 | 2026-11-10 11:22:56.000 | 2026-11-10 11:22:56.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9440538 | 2026-11-10 12:00:00 | 86 | Aframax | Agioi Theodoroi | Port | 3469 | 2 | 2026-11-14 23:59:59.000 | 2026-11-14 23:59:59.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9903918 | 2026-11-10 12:00:00 | 86 | Aframax | Iberian Atlantic Coast | Level0 | 24709 | 4 | 2026-11-10 11:14:14.000 | 2026-11-10 11:14:14.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9737383 | 2026-11-10 12:00:00 | 86 | Aframax | Trieste | Port | 3565 | 2 | 2026-11-16 00:00:00.000 | 2026-11-16 00:00:00.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9417440 | 2026-11-10 12:00:00 | 86 | Aframax | Central Mediterranean | Level0 | 24738 | 4 | 2026-11-10 11:29:24.000 | 2026-11-10 11:29:24.000 | OnSubs | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9407457 | 2026-11-10 12:00:00 | 86 | Aframax | East Mediterranean | Level0 | 24737 | 4 | 2026-11-10 11:28:55.000 | 2026-11-10 11:28:55.000 | OnSubs | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9388778 | 2026-11-10 12:00:00 | 86 | Aframax | East Mediterranean | Level0 | 24737 | 4 | 2026-11-10 11:29:18.000 | 2026-11-10 11:29:18.000 | OnSubs | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
23 rows × 119 columns
Difference between vessel IMOs in relation to point B¶
vessels_in_b_but_not_in_a = (
vessels_in_b.add_suffix("_IN_B")
.merge(
vessels_in_a.add_suffix("_IN_A"), indicator=True, how="left", on="imo"
)
.loc[lambda x: x["_merge"] != "both"]
)
vessels_in_b_but_not_in_a
| day_IN_B | vessel_class_id_IN_B | vessel_class_IN_B | open_location_IN_B | open_location_taxonomy_IN_B | open_location_geo_id_IN_B | open_location_taxonomy_id_IN_B | open_date_from_IN_B | open_date_to_IN_B | availability_state_IN_B | ... | ais_destination_geo_id_IN_A | ais_destination_taxonomy_id_IN_A | eta_to_ais_destination_IN_A | miles_to_ais_destination_IN_A | delays_to_ais_destination_IN_A | eta_load_port_IN_A | eta_distance_load_port_IN_A | eta_basis_port_id_load_port_IN_A | eta_canals_load_port_IN_A | _merge | |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| imo | |||||||||||||||||||||
| 9693082 | 2026-11-06 12:00:00 | 86 | Aframax | La Coruna | Port | 3389 | 2 | 2026-11-06 23:59:59.000 | 2026-11-06 23:59:59.000 | OnSubs | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9693070 | 2026-11-06 12:00:00 | 86 | Aframax | Milazzo | Port | 3557 | 2 | 2026-11-09 23:59:59.000 | 2026-11-09 23:59:59.000 | OnSubs | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9686649 | 2026-11-06 12:00:00 | 86 | Aframax | Central Mediterranean | Level0 | 24738 | 4 | 2026-11-06 10:59:21.000 | 2026-11-06 10:59:21.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9364215 | 2026-11-06 12:00:00 | 86 | Aframax | Red Sea | Level0 | 24778 | 4 | 2026-11-06 09:41:10.000 | 2026-11-06 09:41:10.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9360465 | 2026-11-06 12:00:00 | 86 | Aframax | Red Sea | Level0 | 24778 | 4 | 2026-11-06 11:07:55.000 | 2026-11-06 11:07:55.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9346861 | 2026-11-06 12:00:00 | 86 | Aframax | Agioi Theodoroi | Port | 3469 | 2 | 2026-11-06 23:59:59.000 | 2026-11-06 23:59:59.000 | OnSubs | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9801976 | 2026-11-06 12:00:00 | 86 | Aframax | Algeciras | Port | 3379 | 2 | 2026-11-08 23:59:59.000 | 2026-11-08 23:59:59.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9488011 | 2026-11-06 12:00:00 | 86 | Aframax | Augusta | Port | 3547 | 2 | 2026-11-09 23:59:59.000 | 2026-11-09 23:59:59.000 | OnSubs | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9796731 | 2026-11-06 12:00:00 | 86 | Aframax | Sea of Marmara | Level0 | 24584 | 4 | 2026-11-06 11:16:43.000 | 2026-11-06 11:16:43.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9790995 | 2026-11-06 12:00:00 | 86 | Aframax | Iberian Atlantic Coast | Level0 | 24709 | 4 | 2026-11-06 10:28:11.000 | 2026-11-06 10:28:11.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9309423 | 2026-11-06 12:00:00 | 86 | Aframax | Red Sea | Level0 | 24778 | 4 | 2026-11-10 01:38:02.935 | 2026-11-10 01:38:02.935 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 1014101 | 2026-11-06 12:00:00 | 86 | Aframax | Central Mediterranean | Level0 | 24738 | 4 | 2026-11-10 17:28:27.944 | 2026-11-10 17:28:27.944 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9460576 | 2026-11-06 12:00:00 | 86 | Aframax | Iberian Atlantic Coast | Level0 | 24709 | 4 | 2026-11-06 11:15:10.000 | 2026-11-06 11:15:10.000 | OnSubs | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9927213 | 2026-11-06 12:00:00 | 86 | Aframax | Ain Sukhna | Port | 3370 | 2 | 2026-11-10 00:00:00.000 | 2026-11-10 00:00:00.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9453999 | 2026-11-06 12:00:00 | 86 | Aframax | Iberian Atlantic Coast | Level0 | 24709 | 4 | 2026-11-06 10:14:59.000 | 2026-11-06 10:14:59.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9296195 | 2026-11-06 12:00:00 | 86 | Aframax | Red Sea | Level0 | 24778 | 4 | 2026-11-06 09:29:56.000 | 2026-11-06 09:29:56.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9892975 | 2026-11-06 12:00:00 | 86 | Aframax | Central Mediterranean | Level0 | 24738 | 4 | 2026-11-06 11:17:04.000 | 2026-11-06 11:17:04.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9417799 | 2026-11-06 12:00:00 | 86 | Aframax | Falconara | Port | 3550 | 2 | 2026-11-06 23:59:59.000 | 2026-11-06 23:59:59.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9410648 | 2026-11-06 12:00:00 | 86 | Aframax | East Mediterranean | Level0 | 24737 | 4 | 2026-11-06 11:17:58.000 | 2026-11-06 11:17:58.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9402237 | 2026-11-06 12:00:00 | 86 | Aframax | British Isles | Level0 | 24757 | 4 | 2026-11-06 10:28:45.000 | 2026-11-06 10:28:45.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9711456 | 2026-11-06 12:00:00 | 86 | Aframax | Iberian Atlantic Coast | Level0 | 24709 | 4 | 2026-11-06 11:15:02.000 | 2026-11-06 11:15:02.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
| 9703320 | 2026-11-06 12:00:00 | 86 | Aframax | Iberian Atlantic Coast | Level0 | 24709 | 4 | 2026-11-06 11:15:37.000 | 2026-11-06 11:15:37.000 | Available | ... | NaN | NaN | NaT | NaN | NaN | NaT | NaN | NaN | NaN | left_only |
22 rows × 119 columns
connection.close()