Examples of vega()


Examples of com.opengamma.analytics.financial.equity.option.EquityIndexOptionBlackMethod.vega()

      final Set<ValueRequirement> desiredValues, final ComputationTargetSpecification targetSpec, final ValueProperties resultProperties) {
    final ValueSpecification resultSpec = new ValueSpecification(getValueRequirementNames()[0], targetSpec, resultProperties);
    final EquityIndexOptionBlackMethod model = EquityIndexOptionBlackMethod.getInstance();
    double sum = 0.0;
    for (final EquityIndexOption derivative : vanillaOptions) {
      sum += model.vega(derivative, market);
    }
    return Collections.singleton(new ComputedValue(resultSpec, sum));
  }

}
View Full Code Here

Examples of org.jquantlib.helpers.CRRAmericanDividendOptionHelper.vega()

        final double value = option.NPV();
        final double delta = option.delta();
        final double gamma = option.gamma();
        final double theta = option.theta();
        final double vega  = option.vega(); //TODO
        final double rho   = option.rho()//TODO

        // market price: simply guess something 10% higher than theoretical
        //FIXME final double ivol = option.impliedVolatility(value*1.10);

 
View Full Code Here

Examples of org.jquantlib.helpers.CRREuropeanDividendOptionHelper.vega()

        final double value  = option.NPV();
        final double delta  = option.delta();
        final double gamma  = option.gamma();
        final double theta  = option.theta();
        final double vega   = option.vega(); //TODO
        final double rho    = option.rho()//TODO

        // market price: simply guess something 10% higher than theoretical
        // final double ivol = option.impliedVolatility(value*1.10);

 
View Full Code Here

Examples of org.jquantlib.helpers.FDAmericanDividendOptionHelper.vega()

        final double value = option.NPV();
        final double delta = option.delta();
        final double gamma = option.gamma();
        final double theta = option.theta();
        final double vega  = option.vega();
        final double rho   = option.rho();

        // market price: simply guess something 10% higher than theoretical
        //FIXME
        final double ivol = option.impliedVolatility(value*1.10);
 
View Full Code Here

Examples of org.jquantlib.helpers.FDEuropeanDividendOptionHelper.vega()

        final double value  = option.NPV();
        final double delta  = option.delta();
        final double gamma  = option.gamma();
        final double theta  = option.theta();
        final double vega   = option.vega();
        final double rho    = option.rho();

        // market price: simply guess something 10% higher than theoretical
        //FIXME
        final double ivol = option.impliedVolatility(value*1.10);
 
View Full Code Here

Examples of org.jquantlib.instruments.ContinuousAveragingAsianOption.vega()

                                    calculated.put("delta", option.delta());
                                    calculated.put("gamma", option.gamma());
                                    calculated.put("theta", option.theta());
                                    calculated.put("rho", option.rho());
                                    calculated.put("divRho", option.dividendRho());
                                    calculated.put("vega", option.vega());

                                    final Map<String, Double> expected = new HashMap<String, Double>();
                                    if (value > spot.value() * 1.0e-5) {
                                        // perturb spot and get delta and gamma
                                        /* @Real */final double du = u * 1.0e-4;
 
View Full Code Here

Examples of org.jquantlib.instruments.DiscreteAveragingAsianOption.vega()

                                    calculated.put("delta", option.delta());
                                    calculated.put("gamma", option.gamma());
                                    calculated.put("theta", option.theta());
                                    calculated.put("rho", option.rho());
                                    calculated.put("divRho", option.dividendRho());
                                    calculated.put("vega", option.vega());

                                    final Map<String, Double> expected = new HashMap<String, Double>();
                                    if (value > spot.value() * 1.0e-5) {
                                        // perturb spot and get delta and gamma
                                        final double du = u * 1.0e-4;
 
View Full Code Here

Examples of org.jquantlib.instruments.DividendVanillaOption.vega()

                                /* @Real */ final double value = option.NPV();
                                calculated.put("delta", option.delta());
                                calculated.put("gamma", option.gamma());
                                calculated.put("theta", option.theta());
                                calculated.put("rho",   option.rho());
                                calculated.put("vega",  option.vega());

                                if (value > spot.value()*1.0e-5) {
                                    // perturb spot and get delta and gamma
                                    /* @Real */ final double du = u*1.0e-4;
                                    spot.setValue(u+du);
View Full Code Here

Examples of org.jquantlib.instruments.EuropeanOption.vega()

        vol.setValue(values[i].v);

        option = new EuropeanOption(payoff, exercise);
        option.setPricingEngine(engine);

        calculated = option.vega();
        error = Math.abs(Math.abs(calculated - values[i].result));
        if(error>tolerance) {
            REPORT_FAILURE("vega", payoff, exercise, values[i].s, values[i].q, values[i].r, today, values[i].v,
                    values[i].result, calculated, error, tolerance);
        }
View Full Code Here

Examples of org.jquantlib.instruments.EuropeanOption.vega()

        vol.setValue(values[i].v);

        option = new EuropeanOption(payoff, exercise);
        option.setPricingEngine(engine);

        calculated = option.vega();
        error = Math.abs(Math.abs(calculated - values[i].result));
        if(error>tolerance) {
            REPORT_FAILURE("vega", payoff, exercise, values[i].s, values[i].q, values[i].r, today, values[i].v,
                    values[i].result, calculated, error, tolerance);
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.