test_class.file: modules/ml/src/test/java/org/apache/ignite/ml/tree/impurity/mse/MSEImpurityMeasureTest.java
test_class.identifier: MSEImpurityMeasureTest
test_case.body: @Test
      public void testImpurityRightPart() {
          // Test on right part [1, 2, 2, 1, 1, 1].
          MSEImpurityMeasure impurity = new MSEImpurityMeasure(0, 0, 0, 8, 12, 6);
  
          assertEquals(1.333, impurity.impurity(), 1e-3);
      }
test_case.class_method_signature: MSEImpurityMeasureTest.testImpurityRightPart()
test_case.full_signature: @Test public void testImpurityRightPart()
test_case.identifier: testImpurityRightPart
test_case.invocations: assertEquals impurity
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testImpurityRightPart()
focal_class.declarator: serialVersionUID = 4536394578628409689L
focal_class.modifier: private static final
focal_class.original_string: private static final long serialVersionUID = 4536394578628409689L;
focal_class.type: long
focal_class.var_name: serialVersionUID
focal_class.declarator: leftY
focal_class.modifier: private final
focal_class.original_string: private final double leftY;
focal_class.type: double
focal_class.var_name: leftY
focal_class.declarator: leftY2
focal_class.modifier: private final
focal_class.original_string: private final double leftY2;
focal_class.type: double
focal_class.var_name: leftY2
focal_class.declarator: leftCnt
focal_class.modifier: private final
focal_class.original_string: private final long leftCnt;
focal_class.type: long
focal_class.var_name: leftCnt
focal_class.declarator: rightY
focal_class.modifier: private final
focal_class.original_string: private final double rightY;
focal_class.type: double
focal_class.var_name: rightY
focal_class.declarator: rightY2
focal_class.modifier: private final
focal_class.original_string: private final double rightY2;
focal_class.type: double
focal_class.var_name: rightY2
focal_class.declarator: rightCnt
focal_class.modifier: private final
focal_class.original_string: private final long rightCnt;
focal_class.type: long
focal_class.var_name: rightCnt
focal_class.file: modules/ml/src/main/java/org/apache/ignite/ml/tree/impurity/mse/MSEImpurityMeasure.java
focal_class.identifier: MSEImpurityMeasure
focal_class.interfaces: implements ImpurityMeasure<MSEImpurityMeasure>
focal_class.class_method_signature: MSEImpurityMeasure.MSEImpurityMeasure(double leftY, double leftY2, long leftCnt, double rightY, double rightY2, long rightCnt)
focal_class.full_signature: public  MSEImpurityMeasure(double leftY, double leftY2, long leftCnt, double rightY, double rightY2, long rightCnt)
focal_class.identifier: MSEImpurityMeasure
focal_class.modifiers: public
focal_class.parameters: (double leftY, double leftY2, long leftCnt, double rightY, double rightY2, long rightCnt)
focal_class.signature:  MSEImpurityMeasure(double leftY, double leftY2, long leftCnt, double rightY, double rightY2, long rightCnt)
focal_class.class_method_signature: MSEImpurityMeasure.impurity()
focal_class.full_signature: @Override public double impurity()
focal_class.identifier: impurity
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: double
focal_class.signature: double impurity()
focal_class.class_method_signature: MSEImpurityMeasure.add(MSEImpurityMeasure b)
focal_class.full_signature: @Override public MSEImpurityMeasure add(MSEImpurityMeasure b)
focal_class.identifier: add
focal_class.modifiers: @Override public
focal_class.parameters: (MSEImpurityMeasure b)
focal_class.return: MSEImpurityMeasure
focal_class.signature: MSEImpurityMeasure add(MSEImpurityMeasure b)
focal_class.class_method_signature: MSEImpurityMeasure.subtract(MSEImpurityMeasure b)
focal_class.full_signature: @Override public MSEImpurityMeasure subtract(MSEImpurityMeasure b)
focal_class.identifier: subtract
focal_class.modifiers: @Override public
focal_class.parameters: (MSEImpurityMeasure b)
focal_class.return: MSEImpurityMeasure
focal_class.signature: MSEImpurityMeasure subtract(MSEImpurityMeasure b)
focal_class.class_method_signature: MSEImpurityMeasure.getLeftY()
focal_class.full_signature: public double getLeftY()
focal_class.identifier: getLeftY
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: double
focal_class.signature: double getLeftY()
focal_class.class_method_signature: MSEImpurityMeasure.getLeftY2()
focal_class.full_signature: public double getLeftY2()
focal_class.identifier: getLeftY2
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: double
focal_class.signature: double getLeftY2()
focal_class.class_method_signature: MSEImpurityMeasure.getLeftCnt()
focal_class.full_signature: public long getLeftCnt()
focal_class.identifier: getLeftCnt
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: long
focal_class.signature: long getLeftCnt()
focal_class.class_method_signature: MSEImpurityMeasure.getRightY()
focal_class.full_signature: public double getRightY()
focal_class.identifier: getRightY
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: double
focal_class.signature: double getRightY()
focal_class.class_method_signature: MSEImpurityMeasure.getRightY2()
focal_class.full_signature: public double getRightY2()
focal_class.identifier: getRightY2
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: double
focal_class.signature: double getRightY2()
focal_class.class_method_signature: MSEImpurityMeasure.getRightCnt()
focal_class.full_signature: public long getRightCnt()
focal_class.identifier: getRightCnt
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: long
focal_class.signature: long getRightCnt()
focal_method.body: @Override public double impurity() {
          double impurity = 0;
  
          if (leftCnt > 0)
              impurity += leftY2 - 2.0 * leftY / leftCnt * leftY + Math.pow(leftY / leftCnt, 2) * leftCnt;
  
          if (rightCnt > 0)
              impurity += rightY2 - 2.0 * rightY / rightCnt * rightY + Math.pow(rightY / rightCnt, 2) * rightCnt;
  
          return impurity;
      }
focal_method.class_method_signature: MSEImpurityMeasure.impurity()
focal_method.full_signature: @Override public double impurity()
focal_method.identifier: impurity
focal_method.invocations: pow pow
focal_method.modifiers: @Override public
focal_method.parameters: ()
focal_method.return: double
focal_method.signature: double impurity()