Examples of ReplicationError


Examples of org.jquantlib.samples.util.ReplicationError

      /* @Real */     final Number underlying = new Double(100);
      /* @Volatility */  final Number volatility = new Double(0.20); // 20%
      /* @Rate */        final Number riskFreeRate = new Double(0.05); // 5%
      final Option.Type Call = Option.Type.Call;

      final ReplicationError rp = new ReplicationError(Call, maturity, strike, underlying, volatility, riskFreeRate);

      final int scenarios = 50000;
      int hedgesNum;

      hedgesNum = 21;
      rp.compute(hedgesNum, scenarios);

      hedgesNum = 84;
      rp.compute(hedgesNum, scenarios);

      clock.stopClock();
      clock.log();
    }

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.