46 DeltaScenario(
const QuantLib::ext::shared_ptr<ore::analytics::Scenario>& baseScenario,
47 const QuantLib::ext::shared_ptr<ore::analytics::Scenario>& incrementalScenario);
49 const Date&
asof()
const override {
return delta_->asof(); }
53 const std::string&
label()
const override {
return delta_->label(); }
64 const std::vector<ore::analytics::RiskFactorKey>&
keys()
const override {
return baseScenario_->keys(); }
71 const std::map<std::pair<RiskFactorKey::KeyType, std::string>, std::vector<std::vector<Real>>>&
80 QuantLib::ext::shared_ptr<Scenario>
delta()
const {
return delta_; }
82 QuantLib::ext::shared_ptr<Scenario>
clone()
const override;
84 bool isCloseEnough(
const QuantLib::ext::shared_ptr<Scenario>& s)
const override;
88 QuantLib::ext::shared_ptr<Scenario>
delta_;
const std::map< std::pair< RiskFactorKey::KeyType, std::string >, std::vector< std::vector< Real > > > & coordinates() const override
Get coordinates.
void setAbsolute(const bool b) override
Set if this is an absolute scenario.
const std::string & label() const override
Return the scenario label.
const Date & asof() const override
Return the scenario asof date.
QuantLib::ext::shared_ptr< Scenario > baseScenario_
QuantLib::ext::shared_ptr< Scenario > clone() const override
clones a scenario and returns a pointer to the new object
void add(const ore::analytics::RiskFactorKey &key, Real value) override
Add an element to the scenario.
bool isAbsolute() const override
Is this an absolute or difference scenario?
DeltaScenario()
Constructor.
QuantLib::ext::shared_ptr< Scenario > delta_
bool isCloseEnough(const QuantLib::ext::shared_ptr< Scenario > &s) const override
checks for equality up to numerical differences
bool has(const ore::analytics::RiskFactorKey &key) const override
Check, get, add a single market point.
void setAsof(const Date &d) override
Set the asof date.
const std::vector< ore::analytics::RiskFactorKey > & keys() const override
Risk factor keys for which this scenario provides data.
void setNumeraire(Real n) override
Set the Numeraire ratio n = N(t) / N(0) so that Price(0) = N(0) * E [Price(t) / N(t) ].
void label(const string &s) override
set the label
QuantLib::ext::shared_ptr< Scenario > delta() const
Get delta.
Real getNumeraire() const override
Get Numeraire ratio n = N(t) / N(0) so that Price(0) = N(0) * E [Price(t) / N(t) ].
QuantLib::ext::shared_ptr< Scenario > base() const
Get base.
Data types stored in the scenario class.