Ejemplo n.º 1
0
  private double score(Node y, List<Node> parents) {
    if (score == Score.andersonDarling) {
      return andersonDarlingPASquareStar(y, parents);
    } else if (score == Score.kurtosis) {
      return Math.abs(StatUtils.kurtosis(residual(y, parents)));
    } else if (score == Score.skew) {
      return Math.abs(StatUtils.skewness(residual(y, parents)));
    } else if (score == Score.fifthMoment) {
      return Math.abs(StatUtils.standardizedFifthMoment(residual(y, parents)));
    } else if (score == Score.absoluteValue) {
      return localScoreA(y, parents);
    }

    throw new IllegalStateException();
  }