def test_model(self, classifier, data, output=None):
        """
        Evaluates the built model using the specified test data and returns the classifications.

        :param classifier: the trained classifier to evaluate
        :type classifier: Classifier
        :param data: the data to evaluate on
        :type data: Instances
        :param output: the output generator to use
        :type output: PredictionOutput
        :return: the classifications
        :rtype: ndarray
        """
        if output is None:
            generator = []
        else:
            output.header = data
            generator = [output.jobject]
        cls = javabridge.call(
            self.jobject, "evaluateModel",
            "(Lweka/classifiers/Classifier;Lweka/core/Instances;[Ljava/lang/Object;)[D",
            classifier.jobject, data.jobject, generator)
        if cls is None:
            return None
        else:
            return javabridge.get_env().get_double_array_elements(cls)
def test_model ( self , classifier , data , output = None ) : if output is None : generator = [ ] else : output . header = data generator = [ output . jobject ] cls = javabridge . call ( self . jobject , "evaluateModel" , "(Lweka/classifiers/Classifier;Lweka/core/Instances;[Ljava/lang/Object;)[D" , classifier . jobject , data . jobject , generator ) if cls is None : return None else : return javabridge . get_env ( ) . get_double_array_elements ( cls )
Evaluates the built model using the specified test data and returns the classifications.

        :param classifier: the trained classifier to evaluate
        :type classifier: Classifier
        :param data: the data to evaluate on
        :type data: Instances
        :param output: the output generator to use
        :type output: PredictionOutput
        :return: the classifications
        :rtype: ndarray