|
WebCab Options and Futures Demo v2.5 (J2SE Edition) |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--webcab.lib.finance.futures.FuturesOnCommodities
Within this class we consider the evaluation of futures contracts on commodities of both investment and consumption type.
| Constructor Summary | |
FuturesOnCommodities()
Creates a new instance. |
|
| Method Summary | |
double |
consumptionCommodity(double commodityPrice,
double storageCosts,
double riskFree,
Date evaluationDate,
Date expiryDate,
BusinessCalendar businessCalendar)
Returns the upper bound of the value for a futures contact on an consumption commodity when the present value of the storage cost are known. |
double |
consumptionCommodity(double commodityPrice,
double storageCosts,
double riskFree,
double timeToExpiry)
Returns the upper bound of the value for a futures contact on an consumption commodity when the present value of the storage cost are known. |
double |
consumptionCommodityWithCarry(double commodityPrice,
double convenienceYield,
double costOfCarry,
Date evaluationDate,
Date expiryDate,
BusinessCalendar businessCalendar)
Calculates the price of a consumption commodity. |
double |
consumptionCommodityWithCarry(double commodityPrice,
double convenienceYield,
double costOfCarry,
double timeToExpiry)
Calculates the price of a consumption commodity. |
double |
consumptionCommodityWithProportionateCosts(double commodityPrice,
double storageCosts,
double riskFree,
Date evaluationDate,
Date maturityDate,
BusinessCalendar businessCalendar)
Returns the upper bound of the value for a futures contact on an investment commodity when the storage cost as a proportion of the commodity price are known. |
double |
consumptionCommodityWithProportionateCosts(double commodityPrice,
double storageCosts,
double riskFree,
double timeToExpiry)
Returns the upper bound of the value for a futures contact on an investment commodity when the storage cost as a proportion of the commodity price are known. |
double |
convenienceYield(double commodityPrice,
double storageCosts,
double riskFree,
double futuresPrice,
Date evaluationDate,
Date expiryDate,
BusinessCalendar businessCalendar)
This methods calculates the convenience yield of a consumption commodity when the present value of the cost of storage is known. |
double |
convenienceYield(double commodityPrice,
double storageCosts,
double riskFree,
double futuresPrice,
double timeToExpiry)
This methods calculates the convenience yield of a consumption commodity when the present value of the cost of storage is known. |
double |
convenienceYieldFromCarry(double commodityPrice,
double futuresPrice,
double costOfCarry,
Date evaluationDate,
Date expiryDate,
BusinessCalendar businessCalendar)
Calculates the convenience yield from the cost of carry for a consumption commodity. |
double |
convenienceYieldFromCarry(double commodityPrice,
double futuresPrice,
double costOfCarry,
double timeToExpiry)
Calculates the convenience yield from the cost of carry for a consumption commodity. |
double |
convenienceYieldWithProportionalCosts(double commodityPrice,
double storageCosts,
double riskFree,
double futuresPrice,
Date evaluationDate,
Date expiryDate,
BusinessCalendar businessCalendar)
Returns the convenience yield of a consumption commodity when the storage costs as a proportion of the commodity price is known. |
double |
convenienceYieldWithProportionalCosts(double commodityPrice,
double storageCosts,
double riskFree,
double futuresPrice,
double timeToExpiry)
Returns the convenience yield of a consumption commodity when the storage costs as a proportion of the commodity price is known. |
double |
costOfCarry(double commodityPrice,
double futuresPrice,
Date evaluationDate,
Date expiryDate,
BusinessCalendar businessCalendar)
Calculates the cost of carry of an investment commodity. |
double |
costOfCarry(double commodityPrice,
double futuresPrice,
double timeToExpiry)
Calculates the cost of carry of an investment commodity. |
double |
costOfCarryForConsumption(double commodityPrice,
double futuresPrice,
double convenienceYield,
Date evaluationDate,
Date expiryDate,
BusinessCalendar businessCalendar)
Calculates the cost of carry of a consumption commodity. |
double |
costOfCarryForConsumption(double commodityPrice,
double futuresPrice,
double convenienceYield,
double timeToExpiry)
Calculates the cost of carry of a consumption commodity. |
double |
investmentCommodity(double commodityPrice,
double storageCosts,
double riskFree,
Date evaluationDate,
Date maturityDate,
BusinessCalendar businessCalendar)
Returns the value for a futures contact on an investment commodity when the present value of the storage cost are known. |
double |
investmentCommodity(double commodityPrice,
double storageCosts,
double riskFree,
double timeToExpiry)
Returns the value for a futures contact on an investment commodity when the present value of the storage cost are known. |
double |
investmentCommodityWithCarry(double commodityPrice,
double costOfCarry,
Date evaluationDate,
Date expiryDate,
BusinessCalendar businessCalendar)
Calculates the price of an investment commodity. |
double |
investmentCommodityWithCarry(double commodityPrice,
double costOfCarry,
double timeToExpiry)
Calculates the price of an investment commodity. |
double |
investmentCommodityWithProportionateCosts(double commodityPrice,
double storageCosts,
double riskFree,
Date evaluationDate,
Date maturityDate,
BusinessCalendar businessCalendar)
Returns the value for a futures contact on an investment commodity when the storage cost as a proportion of the commodity price are known. |
double |
investmentCommodityWithProportionateCosts(double commodityPrice,
double storageCosts,
double riskFree,
double timeToExpiry)
Returns the value for a futures contact on an investment commodity when the storage cost as a proportion of the commodity price are known. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public FuturesOnCommodities()
| Method Detail |
public double investmentCommodity(double commodityPrice,
double storageCosts,
double riskFree,
Date evaluationDate,
Date maturityDate,
BusinessCalendar businessCalendar)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commoditystorageCosts - the present value of the storage cost of the commodity during the life of the futures contractriskFree - continuously compounded risk free interest rateevaluationDate - the date when futures contract is evaluatedmaturityDate - the date when the contract maturesbusinessCalendar - The instance of a BusinessCalendar interface implementation. Specify null to select the London business calendar.
FuturesOnCommoditiesDemoException
public double investmentCommodity(double commodityPrice,
double storageCosts,
double riskFree,
double timeToExpiry)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commoditystorageCosts - the present value of the storage cost of the commodity during the life of the futures contractriskFree - continuously compounded risk free interest ratetimeToExpiry - the time period until the future contract expires
FuturesOnCommoditiesDemoException
public double investmentCommodityWithProportionateCosts(double commodityPrice,
double storageCosts,
double riskFree,
Date evaluationDate,
Date maturityDate,
BusinessCalendar businessCalendar)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commoditystorageCosts - the storage costs as a proportion of the commodity price during the life of the contractriskFree - continuously compounded risk free interest rateevaluationDate - the date when futures contract is evaluatedbusinessCalendar - The instance of a BusinessCalendar interface implementation. Specify null to select the London business calendar.
FuturesOnCommoditiesDemoException
public double investmentCommodityWithProportionateCosts(double commodityPrice,
double storageCosts,
double riskFree,
double timeToExpiry)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commoditystorageCosts - the storage costs as a proportion of the commodity price during the life of the contractriskFree - continuously compounded risk free interest ratetimeToExpiry - the time period until the future contract expires
FuturesOnCommoditiesDemoException
public double consumptionCommodity(double commodityPrice,
double storageCosts,
double riskFree,
Date evaluationDate,
Date expiryDate,
BusinessCalendar businessCalendar)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commoditystorageCosts - the present value of the storage costs of the commodity during the life of the futures contractriskFree - continuously compounded risk free interest rateevaluationDate - the date when futures contract is evaluatedexpiryDate - the date when the contract expiresbusinessCalendar - The instance of a BusinessCalendar interface implementation. Specify null to select the London business calendar.
FuturesOnCommoditiesDemoException
public double consumptionCommodity(double commodityPrice,
double storageCosts,
double riskFree,
double timeToExpiry)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commoditystorageCosts - the present value of the storage costs of the commodity during the life of the futures contractriskFree - continuously compounded risk free interest ratetimeToExpiry - the time period until the future contract expires
FuturesOnCommoditiesDemoException
public double consumptionCommodityWithProportionateCosts(double commodityPrice,
double storageCosts,
double riskFree,
Date evaluationDate,
Date maturityDate,
BusinessCalendar businessCalendar)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commoditystorageCosts - the storage costs as a proportion of the commodity price during the life of the contractriskFree - continuously compounded risk free interest rateevaluationDate - the date when futures contract is evaluatedbusinessCalendar - The instance of a BusinessCalendar interface implementation. Specify null to select the London business calendar.
FuturesOnCommoditiesDemoException
public double consumptionCommodityWithProportionateCosts(double commodityPrice,
double storageCosts,
double riskFree,
double timeToExpiry)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commoditystorageCosts - the storage costs as a proportion of the commodity price during the life of the contractriskFree - continuously compounded risk free interest ratetimeToExpiry - the time period until the future contract expires
FuturesOnCommoditiesDemoException
public double convenienceYield(double commodityPrice,
double storageCosts,
double riskFree,
double futuresPrice,
Date evaluationDate,
Date expiryDate,
BusinessCalendar businessCalendar)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commoditystorageCosts - present value of the storage cost of the commodity during the life of the futures contractfuturesPrice - market price of a futures contract on the underlying commodityriskFree - average risk free interest rate during the life of the futures contractevaluationDate - the date when futures contract is evaluatedexpiryDate - the date when the contract maturesbusinessCalendar - The instance of a BusinessCalendar interface implementation. Specify null to select the London business calendar.
FuturesOnCommoditiesDemoException
public double convenienceYield(double commodityPrice,
double storageCosts,
double riskFree,
double futuresPrice,
double timeToExpiry)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commoditystorageCosts - present value of the storage cost of the commodity during the life of the futures contractfuturesPrice - market price of a futures contract on the underlying commoditytimeToExpiry - the time until the above future contract expiresriskFree - average risk free interest rate during the life of the futures contract
FuturesOnCommoditiesDemoException
public double convenienceYieldWithProportionalCosts(double commodityPrice,
double storageCosts,
double riskFree,
double futuresPrice,
Date evaluationDate,
Date expiryDate,
BusinessCalendar businessCalendar)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commoditystorageCosts - storage costs as a proportion of the commodity price during the life of the contractfuturesPrice - market price of a futures contract on the underlying commodityriskFree - continuously compounded risk free interest rateevaluationDate - the date when futures contract is evaluatedexpiryDate - the date when the contract expiresbusinessCalendar - The instance of a BusinessCalendar interface implementation. Specify null to select the London business calendar.
FuturesOnCommoditiesDemoException
public double convenienceYieldWithProportionalCosts(double commodityPrice,
double storageCosts,
double riskFree,
double futuresPrice,
double timeToExpiry)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commoditystorageCosts - storage costs as a proportion of the commodity price during the life of the contractfuturesPrice - market price of a futures contract on the underlying commoditytimeToExpiry - the time until the above contract expiresriskFree - continuously compounded risk free interest rate
FuturesOnCommoditiesDemoException
public double convenienceYieldFromCarry(double commodityPrice,
double futuresPrice,
double costOfCarry,
Date evaluationDate,
Date expiryDate,
BusinessCalendar businessCalendar)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying consumption commodityfuturesPrice - price of a futures contract on the underlying commoditycostOfCarry - the cost of carry of the commodityevaluationDate - the date when futures contract is evaluatedexpiryDate - the date when the contract expiresbusinessCalendar - The instance of a BusinessCalendar interface implementation. Specify null to select the London business calendar.
FuturesOnCommoditiesDemoException
public double convenienceYieldFromCarry(double commodityPrice,
double futuresPrice,
double costOfCarry,
double timeToExpiry)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying consumption commodityfuturesPrice - price of a futures contract on the underlying commoditytimeToExpiry - the time to expiry of the futures contractcostOfCarry - the cost of carry of the commodity
FuturesOnCommoditiesDemoException
public double investmentCommodityWithCarry(double commodityPrice,
double costOfCarry,
Date evaluationDate,
Date expiryDate,
BusinessCalendar businessCalendar)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commoditycostOfCarry - the cost of carry of the underlying commodityevaluationDate - the date when futures contract is evaluatedexpiryDate - the date when the contract expiresbusinessCalendar - The instance of a BusinessCalendar interface implementation. Specify null to select the London business calendar.
FuturesOnCommoditiesDemoException
public double investmentCommodityWithCarry(double commodityPrice,
double costOfCarry,
double timeToExpiry)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commoditycostOfCarry - the cost of carry of the underlying commoditytimeToExpiry - the time period until the futures contract expires
FuturesOnCommoditiesDemoException
public double consumptionCommodityWithCarry(double commodityPrice,
double convenienceYield,
double costOfCarry,
Date evaluationDate,
Date expiryDate,
BusinessCalendar businessCalendar)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commodityconvenienceYield - the convenience yield of the commoditycostOfCarry - the cost of carry of the underlying commodityevaluationDate - the date when futures contract is evaluatedexpiryDate - the date when the contract expiresbusinessCalendar - The instance of a BusinessCalendar interface implementation. Specify null to select the London business calendar.
FuturesOnCommoditiesDemoException
public double consumptionCommodityWithCarry(double commodityPrice,
double convenienceYield,
double costOfCarry,
double timeToExpiry)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commodityconvenienceYield - the convenience yield of the commoditycostOfCarry - the cost of carry of the underlying commoditytimeToExpiry - the time period until the futures contract expires
FuturesOnCommoditiesDemoException
public double costOfCarry(double commodityPrice,
double futuresPrice,
Date evaluationDate,
Date expiryDate,
BusinessCalendar businessCalendar)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commodityfuturesPrice - market price of a futures contract on the underlying commodityevaluationDate - the date when futures contract is evaluatedexpiryDate - the date when the contract expiresbusinessCalendar - The instance of a BusinessCalendar interface implementation. Specify null to select the London business calendar.
FuturesOnCommoditiesDemoException
public double costOfCarry(double commodityPrice,
double futuresPrice,
double timeToExpiry)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commodityfuturesPrice - market price of a futures contract on the underlying commoditytimeToExpiry - the time until expiry of the futures contract
FuturesOnCommoditiesDemoException
public double costOfCarryForConsumption(double commodityPrice,
double futuresPrice,
double convenienceYield,
Date evaluationDate,
Date expiryDate,
BusinessCalendar businessCalendar)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commodityfuturesPrice - the market price of a futures contract on the underlying commodityconvenienceYield - the convenience yield of the commodityevaluationDate - the date when futures contract is evaluatedexpiryDate - the date when the contract expiresbusinessCalendar - The instance of a BusinessCalendar interface implementation. Specify null to select the London business calendar.
FuturesOnCommoditiesDemoException
public double costOfCarryForConsumption(double commodityPrice,
double futuresPrice,
double convenienceYield,
double timeToExpiry)
throws FuturesOnCommoditiesDemoException
commodityPrice - the price of the underlying commodityfuturesPrice - the market price of a futures contract on the underlying commoditytimeToExpiry - the time until the expiry of the above futures contractconvenienceYield - the convenience yield of the commodity
FuturesOnCommoditiesDemoException
|
WebCab Options and Futures Demo v2.5 (J2SE Edition) |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||