Aleš Erjavec avatar Aleš Erjavec committed 53a3b80

Comments (0)

Files changed (3)

widgets/OWBagofWords.py

                     self.attributesCombo.addItem(att.name)
                     self.textAttribute = indx
                     k += 1
-            if not self.textAttribute:
+            if self.textAttribute == None:
                 self.error("The data has no string attributes")
                 self.nDocuments = "N/A"; self.nStrAttributes = "N/A"; self.nWords = "N/A"
                 self.data = None
             self.nStrAttributes = k
         else:
             self.nDocuments = "N/A"; self.nStrAttributes = "N/A"; self.nWords = "N/A"
-            self.send("Bag-of-words", None)
+            self.send("Bag-of-Words", None)
             self.data = data
             return
         self.error() # clear any error message

widgets/OWTextPreprocess.py

         self.langCombo = OWGUI.comboBox(self.controlArea, self, "selectedLanguage", box="Language", addSpace=True)
         for (i, label) in enumerate(btnLabels):
             self.langCombo.addItem(QIcon(QPixmap(os.path.dirname(__file__) + "/icons/" + self.langDict[i] +".png")), label)
-#        self.langCombo.setCurrentItem(self.selectedLanguage)
+        self.langCombo.setCurrentIndex(self.selectedLanguage)
         
         self.attributesCombo = OWGUI.comboBox(self.controlArea, self, "textAttribute", box="Text attribute", callback=self.apply)
         OWGUI.rubber(self.controlArea)
                     self.attributesCombo.addItem(att.name)
                     self.textAttribute = indx
                     k += 1
-            if not self.textAttribute:
+            if self.textAttribute==None:
                 self.error("The data has no string attributes")
                 self.nDocuments = "N/A"; self.nStrAttributes = "N/A"
                 self.data = None

widgets/OWWordNgram.py

 
     def __init__(self, parent=None, signalManager=None, name = "WordNgram"):
         OWWidget.__init__(self,parent,signalManager,name)
-        self.callbackDeposit = []
         self.inputs = [("Example Table", ExampleTable, self.dataset)]
         self.outputs = [("Example Table", ExampleTable)]
 
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.