Skip to main content

EventOptions

An EventOptions is options data (an option chain for each maturity) that is dynamically built from events.

Introduction​

An EventOptions says which events hold the options data and how to read them: one event for each ondate, tenor, call or put, and strike. It is saved as a data item of an object, and the options are built from the events each time you read them. With positions set it becomes a positions view, which returns only the options you hold. See the Options topic.

Construction​

To construct a new EventOptions, use the EventOptions function:

options = EventOptions(eventlist)

An example of constructing EventOptions on the ICE Endex EUA futures options:

options = EventOptions("ICE.NDEX.EFO:OPTIONS")
options.source = "common"

Properties​

An EventOptions has the following properties:

NameDescriptionType
eventThe name of the eventlist that these options use (in the form objectId:eventListId)String
sourceOptional source of the events: private, common or public (default private, public for # event lists)String
filterOptional filter (JSON) used to filter the eventsString
tenorThe name of the property in the event with the tenor/maturity code of the option (default absolute)String
strikeThe name of the property in the event with the strike price (default STRIKE_PRICE)String
callPutThe name of the property in the event that says if the option is a call or a put (default CONTRACT_TYPE)String
callValueThe value of the callPut property for a call option (default C)String
putValueThe value of the callPut property for a put option (default P)String
valueThe main value column, used when no column is given (default SETTLEMENT_PRICE)String
columnsThe event properties shown in the strike table (default SETTLEMENT_PRICE, OPTION_VOLATILITY, DELTA_FACTOR, OPEN_INTEREST, TOTAL_VOLUME)List or String
timezoneThe timezone of the ondates (default UTC)String
calendarThe optional expiry calendar of the optionsString
holidayCalendarThe optional holiday calendar, the calendar of the single option timeseries (default daily)String
currencyAn optional currency codeString
unitsAn optional units codeString
nameThe name of the optionsString
descriptionA description of the optionsString
positionsOptional eventlist with the positions held; when set only the held options are returnedString
positionSourceThe source of the position events: private (default), common or publicString
positionFilterOptional filter (JSON) used to filter the position events, e.g. on a book or productString
positionTenorThe property in the position events with the tenor, absolute or relative (default tenor)String
positionStrikeThe property in the position events with the strike price (default strike)String
positionCallPutThe property in the position events that says if it is a call or a put (default callput)String
positionVolumeThe property in the position events with the volume held, negative for a short position (default volume)String
positionPriceThe property in the position events with the traded price (default price)String
identityThe configured identity for these optionsObject
propertiesAny other properties you want to add onto the optionsObject

Methods​

NameDescriptionReturn Type
build(ondate)Builds these options for an ondate on the server; in your own scripts read ${data:"ID:YYYY-MM-DD"} insteadOptions
ondates()Gets the ondates these options can be built for (on the server)OptionsDates

Reading the options​

IdWhat you get
OBJ:IDThe ondates (OptionsDates)
OBJ:ID:YYYY-MM-DD, OBJ:ID:LThe Options for an ondate, or the latest
OBJ:ID:TENOR:STRIKE:CA TimeSeries of the call's main value, one value per ondate (P for the put)
OBJ:ID:TENOR:STRIKE:C:COLUMNA TimeSeries of one column of the call

Examples​

Creating and saving event options​

o = EventOptions("ICE.NDEX.EFO:OPTIONS")
o.name = "EUA futures options"
o.source = "common"
o.columns = ["SETTLEMENT_PRICE", "OPTION_VOLATILITY", "DELTA_FACTOR"]
NGE = Object()
NGE.id = "NGE.EUA"
NGE.OPTIONS = o
save NGE

Reading the options for an ondate​

eua = ${data:"NGE.EUA:OPTIONS:2026-09-16"}
print eua["2026M09"][85].call.SETTLEMENT_PRICE

A positions view​

p = EventOptions("ICE.NDEX.EFO:OPTIONS")
p.source = "common"
p.positions = "NGE.EUA:POSITIONS"
NGE = Object()
NGE.id = "NGE.EUA"
NGE.POSITIONS_VIEW = p
save NGE

See Traded options for uploading positions.