Build Your Own:
Use get_timeseries_fields() to discover which fields a symbol supports before building a time series query. Build it step by step:
Step 1 — Import the library
import icepython as iceStep 2 — Pick a symbol
symbol = 'BRN 1!-ICE'Step 3 — Call the function to list available fields:
available_fields = ice.get_timeseries_fields(symbol)
print(available_fields)
Step 4 — Use a field in a real time series query. Each pair's first element is the field name you pass to get_timeseries():
data = ice.get_timeseries(symbol, 'Last', 'D',
'2024-01-01', '2024-01-31')
for row in data:
print(row)
Output:
(('Open', 'Open'), ('High', 'High'), ('Low', 'Low'), ('Close', 'Close'), ('Last', 'Last'), ('Volume', 'Volume'), ('Open Interest', 'Open Interest'), ('VWAP Open', 'VWAP Open'), ('VWAP High', 'VWAP High'), ('VWAP Low', 'VWAP Low'), ('VWAP Close', 'VWAP Close'), ('Settle', 'Settle'), ('Block Volume', 'Block Volume'), ('EFS Volume', 'EFS Volume'), ('EFP Volume', 'EFP Volume'), ('Orderbook Volume', 'Orderbook Volume'), ('Block Price Open', 'Block Price Open'), ('Block Price High', 'Block Price High'), ('Block Price Low', 'Block Price Low'), ('Block Price Close', 'Block Price Close'), ('Combined Price Open', 'Combined Price Open'), ('Combined Price High', 'Combined Price High'), ('Combined Price Low', 'Combined Price Low'), ('Combined Price Close', 'Combined Price Close'), ('Vertically Implied Volume', 'Vertically Implied Volume'), ('Spread Volume', 'Spread Volume'), ('Screen Volume', 'Screen Volume'), ('Clearing Volume', 'Clearing Volume'), ('ICE Theoretical Price Open', 'ICE Theoretical Price Open'), ('ICE Theoretical Price High', 'ICE Theoretical Price High'), ('ICE Theoretical Price Low', 'ICE Theoretical Price Low'), ('ICE Theoretical Price Close', 'ICE Theoretical Price Close'), ('Implied Volatility', 'Implied Volatility'))
('Time', 'BRN 1!-ICE.Last')
('2024-01-02', 70.3)
('2024-01-03', 71.61)
('2024-01-04', 70.95)
('2024-01-05', 71.4)
('2024-01-08', 70.21)
('2024-01-09', 70.63)
('2024-01-10', 70.3)
('2024-01-11', 70.76)
('2024-01-12', 71.61)
('2024-01-15', 71.37)
('2024-01-16', 71.19)
('2024-01-17', 70.98)
('2024-01-18', 71.5)
('2024-01-19', 71.03)
('2024-01-22', 72.11)
('2024-01-23', 71.96)
('2024-01-24', 72.2)
('2024-01-25', 73.03)
('2024-01-26', 73.67)
('2024-01-29', 72.87)
('2024-01-30', 73.45)
('2024-01-31', 72.4)