Package org.jquantlib.daycounters

Examples of org.jquantlib.daycounters.Actual360


                new AmericanOptionData(Option.Type.Put, 100.00, 100.00, 0.10, 0.10, 0.50, 0.35, 9.5104),
                new AmericanOptionData(Option.Type.Put, 100.00, 110.00, 0.10, 0.10, 0.50, 0.35, 5.8823) };

        final Date today = new Settings().evaluationDate();

        final DayCounter dc = new Actual360();

        final SimpleQuote           spot  = new SimpleQuote(0.0);
        final SimpleQuote           qRate = new SimpleQuote(0.0);
        final YieldTermStructure    qTS   = Utilities.flatRate(today, qRate, dc);
        final SimpleQuote           rRate = new SimpleQuote(0.0);
View Full Code Here


        QL.info("Testing Ju approximation for American options...");

        final Date today = new Settings().evaluationDate();

        final DayCounter dc = new Actual360();

        final SimpleQuote           spot  = new SimpleQuote(0.0);
        final SimpleQuote           qRate = new SimpleQuote(0.0);
        final YieldTermStructure    qTS   = Utilities.flatRate(today, qRate, dc);
        final SimpleQuote           rRate = new SimpleQuote(0.0);
View Full Code Here

        final Date today = new Settings().evaluationDate();
        final double tolerance = 8.0e-2;

        for (final AmericanOptionData juValue : juValues) {

            final DayCounter dc = new Actual360();

            final SimpleQuote           spot  = new SimpleQuote(0.0);
            final SimpleQuote           qRate = new SimpleQuote(0.0);
            final YieldTermStructure    qTS   = Utilities.flatRate(today, qRate, dc);
            final SimpleQuote           rRate = new SimpleQuote(0.0);
View Full Code Here

        final double qRates[] = { 0.04, 0.05, 0.06 };
        final double rRates[] = { 0.01, 0.05, 0.15 };
        final int years[] = { 1, 2 };
        final double vols[] = { 0.11, 0.50, 1.20 };

        final DayCounter dc = new Actual360();
        final Date today = new Settings().evaluationDate();

        final SimpleQuote           spot  = new SimpleQuote(0.0);
        final SimpleQuote           qRate = new SimpleQuote(0.0);
        final YieldTermStructure    qTS   = Utilities.flatRate(today, qRate, dc);
View Full Code Here

        final BSMOperator ref = new BSMOperator(grid.size(), dx, r, q, sigma);
        QL.info("BSMOperator reference diagonals: \n");
        outputDiagonals(ref);

        final DayCounter dc = new Actual360();

        final Date today = Date.todaysDate();

        Date exercise = today.clone();
        exercise = exercise.add(new Period(2,TimeUnit.Years));


        final double residualTime = dc.yearFraction(today, exercise);

        final SimpleQuote spot = new SimpleQuote(0.0);
        final YieldTermStructure qTS = Utilities.flatRate(today, q, dc);
        final YieldTermStructure rTS = Utilities.flatRate(today, r, dc);
View Full Code Here

TOP

Related Classes of org.jquantlib.daycounters.Actual360

Copyright © 2018 www.massapicom. 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.