(self, data, fixed=None)
return Domain(new_attrs, new_classes)
Compute and return discretized domain.

        :param data: Data to discretize.
Compute and return discretized domain.
Compute and return discretized domain .
def __call__(self, data, fixed=None):
        """
        Compute and return discretized domain.

        :param data: Data to discretize.
        """

        def transform_list(s, fixed=None):
            new_vars = []
            for var in s:
                if var.is_continuous:
                    if fixed and var.name in fixed.keys():
                        nv = method(data, var, fixed)
                    else:
                        nv = method(data, var)
                    if not self.clean or len(nv.values) > 1:
                        new_vars.append(nv)
                else:
                    new_vars.append(var)
            return new_vars
        if self.method is None:
            method = EqualFreq(n=4)
        else:
            method = self.method
        domain = data.domain
        new_attrs = transform_list(domain.attributes, fixed or self.fixed)
        if self.discretize_class:
            new_classes = transform_list(domain.class_vars)
        else:
            new_classes = domain.class_vars
        return Domain(new_attrs, new_classes)
def __call__ ( self , data , fixed = None ) : def transform_list ( s , fixed = None ) : new_vars = [ ] for var in s : if var . is_continuous : if fixed and var . name in fixed . keys ( ) : nv = method ( data , var , fixed ) else : nv = method ( data , var ) if not self . clean or len ( nv . values ) > 1 : new_vars . append ( nv ) else : new_vars . append ( var ) return new_vars if self . method is None : method = EqualFreq ( n = 4 ) else : method = self . method domain = data . domain new_attrs = transform_list ( domain . attributes , fixed or self . fixed ) if self . discretize_class : new_classes = transform_list ( domain . class_vars ) else : new_classes = domain . class_vars return Domain ( new_attrs , new_classes )