f66d5ef4c6fd35b1a7d099e0c93cbdfdbdbc7902,Orange/feature/discretization.py,EqualFreq,__call__,#EqualFreq#Any#Any#,80

Before Change


            param = (data.table_name, attribute.name, filters if filters else None, self.n)
            cur = data._execute_sql_query(sql, param)

            points = [a for a, in cur.fetchall()]
        else:
            d = Orange.statistics.distribution.get_distribution(data, attribute)
            points = _discretization.split_eq_freq(d, n=self.n)
        return _discretized_var(data, attribute, points)

After Change


            att = attribute.to_sql()
            quantiles = [(i + 1) / self.n for i in range(self.n - 1)]
            cur = data._sql_query(["quantile(%s, ARRAY%s)" % (att, str(quantiles))], filters)
            points = cur.fetchone()[0]
        else:
            d = Orange.statistics.distribution.get_distribution(data, attribute)
            points = _discretization.split_eq_freq(d, n=self.n)
        return _discretized_var(data, attribute, points)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 6

Instances


Project Name: biolab/orange3
Commit Name: f66d5ef4c6fd35b1a7d099e0c93cbdfdbdbc7902
Time: 2014-06-18
Author: lan.zagar@fri.uni-lj.si
File Name: Orange/feature/discretization.py
Class Name: EqualFreq
Method Name: __call__


Project Name: ANSSI-FR/SecuML
Commit Name: f37a2477721902d17410e75dfcde5df3b49db9ca
Time: 2017-08-01
Author: anael.bonneton@ssi.gouv.fr
File Name: code/SecuML/Data/idents_tools.py
Class Name:
Method Name: getAllIdents


Project Name: biolab/orange3
Commit Name: f66d5ef4c6fd35b1a7d099e0c93cbdfdbdbc7902
Time: 2014-06-18
Author: lan.zagar@fri.uni-lj.si
File Name: Orange/feature/discretization.py
Class Name: EqualWidth
Method Name: __call__