Examples of WeightingFunction


Examples of com.opengamma.analytics.financial.model.volatility.smile.fitting.interpolation.WeightingFunction

      final String volatilityFunctionName = message.getString(VOLATILITY_MODEL_FIELD_NAME);
      final String weightingFunctionName = message.getString(WEIGHTING_FUNCTION_FIELD_NAME);
      final boolean externalBeta = message.getBoolean(EXTERNAL_BETA_FIELD_NAME);
      @SuppressWarnings("unchecked")
      final VolatilityFunctionProvider<SABRFormulaData> model = (VolatilityFunctionProvider<SABRFormulaData>) VolatilityFunctionFactory.getCalculator(volatilityFunctionName);
      final WeightingFunction weightingFunction = WeightingFunctionFactory.getWeightingFunction(weightingFunctionName);
      if (externalBeta) {
        final double beta = message.getDouble(BETA_FIELD_NAME);
        return new SmileInterpolatorSABR(model, beta, weightingFunction);
      }
      return new SmileInterpolatorSABR(model, weightingFunction);
View Full Code Here

Examples of com.opengamma.analytics.financial.model.volatility.smile.fitting.interpolation.WeightingFunction

  }

  @Override
  protected GeneralSmileInterpolator getSmileInterpolator(final ValueRequirement desiredValue) {
    final String weightingFunctionName = desiredValue.getConstraint(PROPERTY_MIXED_LOG_NORMAL_WEIGHTING_FUNCTION);
    final WeightingFunction weightingFunction = WeightingFunctionFactory.getWeightingFunction(weightingFunctionName);
    return new SmileInterpolatorMixedLogNormal(weightingFunction);
  }
View Full Code Here

Examples of com.opengamma.analytics.financial.model.volatility.smile.fitting.interpolation.WeightingFunction

  @Override
  protected GeneralSmileInterpolator getSmileInterpolator(final ValueRequirement desiredValue) {
    final String modelName = desiredValue.getConstraint(PROPERTY_SABR_MODEL);
    final String weightingFunctionName = desiredValue.getConstraint(PROPERTY_SABR_WEIGHTING_FUNCTION);
    final VolatilityFunctionProvider<SABRFormulaData> model = (VolatilityFunctionProvider<SABRFormulaData>) VolatilityFunctionFactory.getCalculator(modelName);
    final WeightingFunction weightingFunction = WeightingFunctionFactory.getWeightingFunction(weightingFunctionName);
    final boolean useExternalBeta = Boolean.parseBoolean(desiredValue.getConstraint(PROPERTY_SABR_USE_EXTERNAL_BETA));
    if (useExternalBeta) {
      final double beta = Double.parseDouble(desiredValue.getConstraint(PROPERTY_SABR_EXTERNAL_BETA));
      return new SmileInterpolatorSABR(model, beta, weightingFunction);
    }
View Full Code Here

Examples of edu.ucla.sspace.hal.WeightingFunction

    /**
     * {@inheritDoc}
     */
    protected SemanticSpace getSpace() {
        WeightingFunction weighting;
        if (argOptions.hasOption('W'))
            weighting = ReflectionUtil.getObjectInstance(argOptions.getStringOption('W'));
        else
            weighting = new LinearWeighting();
        int windowSize = argOptions.getIntOption('s', 5);
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.