## OI Term Rate

OI Term Rate is a
direct subtype of Term Rate with functions OI Term Rate Functions, keys OI Term Rate keys and example object OiTermRt that represents an overnight index (oi) term rate R over a given period [T₀,Tₙ], referred below as the "observation period".
The observation period is context-dependent and depends on the floating accrual period [Tₛ,Tₑ] associated with the considered term rate R
For example, a 5Y OIS usually has 5 floating accrual periods and each of them is associated with a corresponding oi term rate.
If one of these 5 periods is denoted as [Tₛ,Tₑ], the corresponding oi term rate R will have an observation period [T₀,Tₙ] that is constructed as described below.

First a reference period [T'₀,T'ₙ] is constructed with its boundary dates T'₀ and [T'₀,T'ₙ] as follows:
T'₀ = Tₛ + δₛ, where δₛ is a time interval that may be optionally defined as offset to the start date Tₛ of the applicable floating accrual period [Tₛ,Tₑ]
T'ₙ = T* + δₑ, where δₛ is a time interval that may be optionally defined as offset to the date T*
Here the date T* depends on the time interval δ specified in the entry
Tenor
If δ is defined, T* = T'₀ + δ
If δ is not defined, T* = Tₑ, where Tₑ is the end date of the applicable floating accrual period [Tₛ,Tₑ]

Then the final observation interval [T₀,Tₙ] is constructed by shifting the [T'₀,T'ₙ] backwards by o business days specified in the entry
Obs Lag

R is defined as a certain average of the values of a referenced overnight rate I observed over [T₀,Tₙ]
The type of average is specified by an element from the list
Build Rule

In particular, assume the observation period consists of n+1 consecutive business dates T₀, T₁,..., Tₙ and for each i = 0,...,n-1, the overnight value Iᵢ is assumed to apply on the interval [Tᵢ,Tᵢ₊₁]
The value Iᵢ may have been set prior to Tᵢ
In fact, if the overnight index I has an inherent fixing lag period of ε business days, the value Iᵢ will have been set on Tᵢ-ε
If an additional so called "lookback" period λ is specified in the entry
Lookback, the value Iᵢ will have been set on Tᵢ-ε-λ

R's definition depends on the selected type of average.

In the
Compound case, R is defined as:
R = [Π(1+IᵢΔᵢ) - 1] / Δt

In the
Average case, R is defined as:
R = [Σ(IᵢΔᵢ)] / Δt

Above, Π is the product over all i and Σ is the sum over all i, in both cases for i = 0,...,n-1
Δᵢ is the length of the interval [Tᵢ,Tᵢ₊₁] in annual units
Δt is the period's [T₀,Tₙ] length in annual units

The following feature is also supported:
Rate Cutoff