def evaluate_method(method, events, aux=<NUM_LIT:0.>):
if not isinstance(method, TMVA.MethodBase):<EOL><INDENT>raise TypeError("<STR_LIT>")<EOL><DEDENT>events = np.ascontiguousarray(events, dtype=np.float64)<EOL>if events.ndim == <NUM_LIT:1>:<EOL><INDENT>events = events[:, np.newaxis]<EOL><DEDENT>elif events.ndim != <NUM_LIT:2>:<EOL><INDENT>raise ValueError(<EOL>"<STR_LIT>"<EOL>"<STR_LIT>")<EOL><DEDENT>return _libtmvanumpy.evaluate_method(ROOT.AsCObject(method), events, aux)<EOL>
Evaluate a TMVA::MethodBase over a NumPy array.

    .. warning:: TMVA::Reader has known problems with thread safety in versions
       of ROOT earlier than 6.03. There will potentially be a crash if you call
       ``method = reader.FindMVA(name)`` in Python and then pass this
       ``method`` here. Consider using ``evaluate_reader`` instead if you are
       affected by this crash.

    Parameters
    ----------
    method : TMVA::MethodBase
        A TMVA::MethodBase instance with variables booked in exactly the same
        order as the columns in ``events``.
    events : numpy array of shape [n_events, n_variables]
        A two-dimensional NumPy array containing the rows of events and columns
        of variables. The order of the columns must match the order in which
        you called ``AddVariable()`` for each variable.
    aux : float, optional (default=0.)
        Auxiliary value used by MethodCuts to set the desired signal
        efficiency.

    Returns
    -------
    output : numpy array of shape [n_events]
        The method output value for each event

    See Also
    --------
    evaluate_reader