Previous Topic

Next Topic

oSWPcmd1_Price_FX( ) - Commodity Swap 1 Fixed Leg Price Function

Component

Resolution - Swap Pricing

 

 

Function Definition

oSWPcmd1_Price_FX(ValueDate, SettlementDate, EffectiveDate, MaturityDate, Price, PaymentFreq, Quantity, BusinessDayConv, DateGeneration, InterpMethod, ZeroCurve, HolidaySchedule, OutputFlag)

Calculates the fair value for the fixed leg of a vanilla commodity swap. Also returns the par swap rate denominator and par rate adjustment.

 

 

Swap Types

Commodity swaps.

 

 

Function Parameters

 

Parameters

Description

 

Parameter Type

 

Restrictions

.

ValueDate

 

The valuation date of the swap.

 

Date

 

ValDate < SettleDate

SettlementDate

 

The date on which the trade will settle. This is typically 1-3 business days after the trade.

 

Date

 

SettleDate < MatDate

EffectiveDate

 

The start date of the swap.

 

Date

 

EffDate < MatDate

MaturityDate

 

The maturity date of the swap.

 

Date

 

As above.

Price

 

The price per unit.

 

Double

 

Price >= 0

PaymentFreq

 

The frequency of the payments.

 

Enumerated Constant

 

1 - Annual
2 - Semi-Annual
3 - Quarterly
4 - Monthly
5 - Bi-Weekly
6 - Weekly

Quantity

 

The number of units of the commodity traded at each payment date.

Double

 

Quantity >= 0

BusinesDayConv

 

Business day convention. Used to determine the start and end date of each payment period.

See Business Day Conventions

 

Enumerated Constant

 

1 - No Adjustment
2 - Previous
3 - Following
4 - Mod Previous
5 - Mod Following
6 - EOM No Adjust
7 - EOM previous
8 - EOM following

DateGeneration

 

Determines if the reset cycle is computed backwards from the maturity date or forwards from the effective date.

 

Enumerated Constant

 

1 - Maturity Date
2 - Effective Date

InterpMethod

 

Method used to calculate rates and discount factors from the supplied zero curve.

 

Enumerated Constant

 

1 - Discount Factors
2 - Zero Rates

ZeroCurve

 

The zero curve that is used to discount cash flows for the fixed leg.

 

Curve

 

 

HolidaySchedule

 

Schedule of non-business days (excluding weekends)

 

Date Range

 

Leave blank if not applicable

OutputFlag

 

Indicates which result, or set of results, will be displayed in the worksheet. When returning more than one value, the function must be entered as an array function. Entering a 0 will output: Fair Value, Par Price Denominator, and Par Price Adjustment.

 

Enumerated Constant

 

0 - All Swap Values
1 - Fair Value
2 - Par Price Denominator and Par Price Adjustment

 

 

 

 

 

 

 

Return to www.derivativepricing.com website

Copyright 2013 Hedgebook Ltd.