@Test public void betterThan() { AnalysisCriterion criterion = new AverageProfitCriterion(); assertTrue(criterion.betterThan(2.0, 1.5)); assertFalse(criterion.betterThan(1.5, 2.0)); }
@Override public boolean betterThan(double criterionValue1, double criterionValue2) { return criterionValue1 > criterionValue2; }
AverageProfitCriterion extends AbstractAnalysisCriterion { @Override public boolean betterThan(double criterionValue1, double criterionValue2) { return criterionValue1 > criterionValue2; } }
AverageProfitCriterion extends AbstractAnalysisCriterion { @Override public boolean betterThan(double criterionValue1, double criterionValue2) { return criterionValue1 > criterionValue2; }  }
AverageProfitCriterion extends AbstractAnalysisCriterion { @Override public boolean betterThan(double criterionValue1, double criterionValue2) { return criterionValue1 > criterionValue2; }  @Override double calculate(TimeSeries series, TradingRecord tradingRecord); @Override double calculate(TimeSeries series, Trade trade); @Override boolean betterThan(double criterionValue1, double criterionValue2); }
AverageProfitCriterion extends AbstractAnalysisCriterion { @Override public boolean betterThan(double criterionValue1, double criterionValue2) { return criterionValue1 > criterionValue2; }  @Override double calculate(TimeSeries series, TradingRecord tradingRecord); @Override double calculate(TimeSeries series, Trade trade); @Override boolean betterThan(double criterionValue1, double criterionValue2);  }