| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
QuantLib.Instrument
Synopsis
- data PositionType
- data SettlementType
- data SettlementMethod
- data CallabilityType
- data OptionType
- data BarrierType
- data AverageType
- data Seniority
- data PricingModel
- type Instrument = GenInstrument CInstrument
- asInstrument :: GenInstrument a -> IO Instrument
- data Callability
- = Soft !Double !BondPriceType !Day !Double
- | Callability !Double !BondPriceType !CallabilityType !Day
- data Exercise
- data ExerciseType
- npv :: GenInstrument a -> IO Double
- errorEstimate :: GenInstrument a -> IO Double
- isExpired :: GenInstrument a -> IO Bool
- valuationDate :: GenInstrument a -> IO Day
- composite :: [(Instrument, Double)] -> IO Instrument
- setPricingEngine :: GenInstrument a -> PricingEngine -> IO ()
Documentation
data PositionType #
Instances
| Enum PositionType # | |
Defined in QuantLib.Internal.Enum Methods succ :: PositionType -> PositionType # pred :: PositionType -> PositionType # toEnum :: Int -> PositionType # fromEnum :: PositionType -> Int # enumFrom :: PositionType -> [PositionType] # enumFromThen :: PositionType -> PositionType -> [PositionType] # enumFromTo :: PositionType -> PositionType -> [PositionType] # enumFromThenTo :: PositionType -> PositionType -> PositionType -> [PositionType] # | |
| Show PositionType # | |
Defined in QuantLib.Internal.Enum Methods showsPrec :: Int -> PositionType -> ShowS # show :: PositionType -> String # showList :: [PositionType] -> ShowS # | |
| Eq PositionType # | |
Defined in QuantLib.Internal.Enum | |
data SettlementType #
Instances
| Enum SettlementType # | |
Defined in QuantLib.Instrument Methods succ :: SettlementType -> SettlementType # pred :: SettlementType -> SettlementType # toEnum :: Int -> SettlementType # fromEnum :: SettlementType -> Int # enumFrom :: SettlementType -> [SettlementType] # enumFromThen :: SettlementType -> SettlementType -> [SettlementType] # enumFromTo :: SettlementType -> SettlementType -> [SettlementType] # enumFromThenTo :: SettlementType -> SettlementType -> SettlementType -> [SettlementType] # | |
| Show SettlementType # | |
Defined in QuantLib.Instrument Methods showsPrec :: Int -> SettlementType -> ShowS # show :: SettlementType -> String # showList :: [SettlementType] -> ShowS # | |
| Eq SettlementType # | |
Defined in QuantLib.Instrument Methods (==) :: SettlementType -> SettlementType -> Bool # (/=) :: SettlementType -> SettlementType -> Bool # | |
data SettlementMethod #
Instances
| Enum SettlementMethod # | |
Defined in QuantLib.Instrument Methods succ :: SettlementMethod -> SettlementMethod # pred :: SettlementMethod -> SettlementMethod # toEnum :: Int -> SettlementMethod # fromEnum :: SettlementMethod -> Int # enumFrom :: SettlementMethod -> [SettlementMethod] # enumFromThen :: SettlementMethod -> SettlementMethod -> [SettlementMethod] # enumFromTo :: SettlementMethod -> SettlementMethod -> [SettlementMethod] # enumFromThenTo :: SettlementMethod -> SettlementMethod -> SettlementMethod -> [SettlementMethod] # | |
| Show SettlementMethod # | |
Defined in QuantLib.Instrument Methods showsPrec :: Int -> SettlementMethod -> ShowS # show :: SettlementMethod -> String # showList :: [SettlementMethod] -> ShowS # | |
| Eq SettlementMethod # | |
Defined in QuantLib.Instrument Methods (==) :: SettlementMethod -> SettlementMethod -> Bool # (/=) :: SettlementMethod -> SettlementMethod -> Bool # | |
data CallabilityType #
Constructors
| CallabilityCall | |
| CallabilityPut |
Instances
| Enum CallabilityType # | |
Defined in QuantLib.Internal.Enum Methods succ :: CallabilityType -> CallabilityType # pred :: CallabilityType -> CallabilityType # toEnum :: Int -> CallabilityType # fromEnum :: CallabilityType -> Int # enumFrom :: CallabilityType -> [CallabilityType] # enumFromThen :: CallabilityType -> CallabilityType -> [CallabilityType] # enumFromTo :: CallabilityType -> CallabilityType -> [CallabilityType] # enumFromThenTo :: CallabilityType -> CallabilityType -> CallabilityType -> [CallabilityType] # | |
| Show CallabilityType # | |
Defined in QuantLib.Internal.Enum Methods showsPrec :: Int -> CallabilityType -> ShowS # show :: CallabilityType -> String # showList :: [CallabilityType] -> ShowS # | |
| Eq CallabilityType # | |
Defined in QuantLib.Internal.Enum Methods (==) :: CallabilityType -> CallabilityType -> Bool # (/=) :: CallabilityType -> CallabilityType -> Bool # | |
data OptionType #
Instances
| Enum OptionType # | |
Defined in QuantLib.Internal.Enum Methods succ :: OptionType -> OptionType # pred :: OptionType -> OptionType # toEnum :: Int -> OptionType # fromEnum :: OptionType -> Int # enumFrom :: OptionType -> [OptionType] # enumFromThen :: OptionType -> OptionType -> [OptionType] # enumFromTo :: OptionType -> OptionType -> [OptionType] # enumFromThenTo :: OptionType -> OptionType -> OptionType -> [OptionType] # | |
| Show OptionType # | |
Defined in QuantLib.Internal.Enum Methods showsPrec :: Int -> OptionType -> ShowS # show :: OptionType -> String # showList :: [OptionType] -> ShowS # | |
| Eq OptionType # | |
Defined in QuantLib.Internal.Enum | |
data BarrierType #
Instances
| Enum BarrierType # | |
Defined in QuantLib.Instrument Methods succ :: BarrierType -> BarrierType # pred :: BarrierType -> BarrierType # toEnum :: Int -> BarrierType # fromEnum :: BarrierType -> Int # enumFrom :: BarrierType -> [BarrierType] # enumFromThen :: BarrierType -> BarrierType -> [BarrierType] # enumFromTo :: BarrierType -> BarrierType -> [BarrierType] # enumFromThenTo :: BarrierType -> BarrierType -> BarrierType -> [BarrierType] # | |
| Show BarrierType # | |
Defined in QuantLib.Instrument Methods showsPrec :: Int -> BarrierType -> ShowS # show :: BarrierType -> String # showList :: [BarrierType] -> ShowS # | |
| Eq BarrierType # | |
Defined in QuantLib.Instrument | |
data AverageType #
Constructors
| Arithmetic | |
| Geometric |
Instances
| Enum AverageType # | |
Defined in QuantLib.Instrument Methods succ :: AverageType -> AverageType # pred :: AverageType -> AverageType # toEnum :: Int -> AverageType # fromEnum :: AverageType -> Int # enumFrom :: AverageType -> [AverageType] # enumFromThen :: AverageType -> AverageType -> [AverageType] # enumFromTo :: AverageType -> AverageType -> [AverageType] # enumFromThenTo :: AverageType -> AverageType -> AverageType -> [AverageType] # | |
| Show AverageType # | |
Defined in QuantLib.Instrument Methods showsPrec :: Int -> AverageType -> ShowS # show :: AverageType -> String # showList :: [AverageType] -> ShowS # | |
| Eq AverageType # | |
Defined in QuantLib.Instrument | |
Constructors
| SecDom | |
| SeniorSec | |
| SnrFor | |
| SeniorUnSec | |
| SubLT2 | |
| SubLoweTier2 | |
| JrSubT2 | |
| SubUpperTier2 | |
| PrefT1 | |
| SubTier1 | |
| NoSeniority |
Instances
| Enum Seniority # | |
Defined in QuantLib.Instrument Methods succ :: Seniority -> Seniority # pred :: Seniority -> Seniority # fromEnum :: Seniority -> Int # enumFrom :: Seniority -> [Seniority] # enumFromThen :: Seniority -> Seniority -> [Seniority] # enumFromTo :: Seniority -> Seniority -> [Seniority] # enumFromThenTo :: Seniority -> Seniority -> Seniority -> [Seniority] # | |
| Show Seniority # | |
| Eq Seniority # | |
data PricingModel #
Instances
| Enum PricingModel # | |
Defined in QuantLib.Instrument Methods succ :: PricingModel -> PricingModel # pred :: PricingModel -> PricingModel # toEnum :: Int -> PricingModel # fromEnum :: PricingModel -> Int # enumFrom :: PricingModel -> [PricingModel] # enumFromThen :: PricingModel -> PricingModel -> [PricingModel] # enumFromTo :: PricingModel -> PricingModel -> [PricingModel] # enumFromThenTo :: PricingModel -> PricingModel -> PricingModel -> [PricingModel] # | |
| Show PricingModel # | |
Defined in QuantLib.Instrument Methods showsPrec :: Int -> PricingModel -> ShowS # show :: PricingModel -> String # showList :: [PricingModel] -> ShowS # | |
| Eq PricingModel # | |
Defined in QuantLib.Instrument | |
type Instrument = GenInstrument CInstrument #
asInstrument :: GenInstrument a -> IO Instrument #
data Callability #
Constructors
| Soft | |
Fields
| |
| Callability !Double !BondPriceType !CallabilityType !Day | |
Constructors
| AmericanExercise | |
| Early !ExerciseType !Bool | |
| Vanilla !ExerciseType | |
| European !EuropeanExercise | |
| Bermudan !BermudanExercise | |
data ExerciseType #
Instances
| Enum ExerciseType # | |
Defined in QuantLib.Internal.Enum Methods succ :: ExerciseType -> ExerciseType # pred :: ExerciseType -> ExerciseType # toEnum :: Int -> ExerciseType # fromEnum :: ExerciseType -> Int # enumFrom :: ExerciseType -> [ExerciseType] # enumFromThen :: ExerciseType -> ExerciseType -> [ExerciseType] # enumFromTo :: ExerciseType -> ExerciseType -> [ExerciseType] # enumFromThenTo :: ExerciseType -> ExerciseType -> ExerciseType -> [ExerciseType] # | |
| Show ExerciseType # | |
Defined in QuantLib.Internal.Enum Methods showsPrec :: Int -> ExerciseType -> ShowS # show :: ExerciseType -> String # showList :: [ExerciseType] -> ShowS # | |
| Eq ExerciseType # | |
Defined in QuantLib.Internal.Enum | |
npv :: GenInstrument a -> IO Double #
Returns the net present value of the given Instrument
returns the error estimate on the NPV when available.
errorEstimate :: GenInstrument a -> IO Double #
returns whether the instrument might have value greater than zero.
valuationDate :: GenInstrument a -> IO Day #
composite :: [(Instrument, Double)] -> IO Instrument #
setPricingEngine :: GenInstrument a -> PricingEngine -> IO () #