Changeset 9598:2fcfcfd5b6b9 in orange for orange/OrangeWidgets/Prototypes/OWGaussianMixtures.py
Legend:
 Unmodified
 Added
 Removed

orange/OrangeWidgets/Prototypes/OWGaussianMixtures.py
r9546 r9598 11 11 from Orange.clustering import mixture 12 12 13 GM_PARAMS = [{"name": "n _centers",13 GM_PARAMS = [{"name": "n", 14 14 "type": int, 15 15 "default": 3, … … 26 26 27 27 class OWGaussianMixtures(OWWidget): 28 settingsList = ["init_method", "n _centers"]28 settingsList = ["init_method", "n"] 29 29 30 30 def __init__(self, parent=None, signalManager=None, title="Gaussin Mixture"): … … 35 35 36 36 self.init_method = 0 37 self.n _centers= 337 self.n = 3 38 38 self.auto_commit = True 39 39 … … 44 44 ##### 45 45 46 OWGUI.spin(self.controlArea, self, "n _centers", min=1, max=10, step=1,46 OWGUI.spin(self.controlArea, self, "n", min=1, max=10, step=1, 47 47 box="Settings", 48 48 label="Number of gaussians", … … 70 70 71 71 gmm = mixture.GaussianMixture(self.input_data, 72 n _centers=self.n_centers,72 n=self.n, 73 73 init_function=init_function) 74 input_matrix, _, _ = self.input_data.to_numpy_MA() 74 75 data = self.input_data.translate(gmm.domain) 76 77 input_matrix, _, _ = data.to_numpy_MA() 75 78 self.gmm = gmm 76 79
Note: See TracChangeset
for help on using the changeset viewer.