HQu-0.0.0.3: quantitative finance library
Safe HaskellNone
LanguageHaskell2010

Q.ContingentClaim

Synopsis

Documentation

data CashFlow Source #

A cash flow is a time and amount.

Constructors

CashFlow 

Fields

Instances

Instances details
Eq CashFlow Source # 
Instance details

Defined in Q.ContingentClaim

Show CashFlow Source # 
Instance details

Defined in Q.ContingentClaim

data CCProcessor a Source #

Stop at time t and potentially apply n payouts up to the monitoring time.

Constructors

CCProcessor 

Fields

newtype ContingentClaim a Source #

A claim contingent on some observable a.

An example of an observable is a spot driven asset, such as a stock.

Constructors

ContingentClaim 

Fields

multiplier :: Double -> ContingentClaim a -> ContingentClaim a Source #

multipley a contingent claim by its notional.

short :: ContingentClaim a -> ContingentClaim a Source #

Change direction of the portfolio

type CCBuilder w r a = WriterT w (Reader r) a Source #

monitor :: LocalTime -> CCBuilder (ContingentClaim a) (Map LocalTime a) a Source #

Monitor an observable at the given time t.

pay :: forall a. LocalTime -> CCBuilder (ContingentClaim a) (Map LocalTime a) CashFlow -> ContingentClaim a Source #

Pay an amount at a given time