Changeset 8752:28c8f7ee5433 in orange


Ignore:
Timestamp:
08/24/11 10:01:00 (3 years ago)
Author:
matejd <matejd@…>
Branch:
default
Convert:
86ec0abbf5f3a47a49f895799b4ab195db6cbdb4
Message:

Removed performance tab and some checkboxes from LinProj3D

Location:
orange/OrangeWidgets
Files:
31 deleted
1 edited

Legend:

Unmodified
Added
Removed
  • orange/OrangeWidgets/Visualize Qt/OWLinProjQt.py

    r8750 r8752  
    4343        self.outputs = [("Selected Examples", ExampleTable), ("Unselected Examples", ExampleTable), ("Attribute Selection List", AttributeList), ("FreeViz Learner", orange.Learner)] 
    4444 
     45        name_lower = name.lower() 
     46 
    4547        # local variables 
    4648        self.showAllAttributes = 0 
     
    9193 
    9294        # optimization dialog 
    93         if "radviz" in name.lower(): 
     95        if "radviz" in name_lower: 
    9496            self.vizrank = OWVizRank(self, self.signalManager, self.graph, orngVizRank.RADVIZ, name) 
    9597            self.connect(self.graphButton, SIGNAL("clicked()"), self.saveToFile) 
    96         elif "polyviz" in name.lower(): 
     98        elif "polyviz" in name_lower: 
    9799            self.vizrank = OWVizRank(self, self.signalManager, self.graph, orngVizRank.POLYVIZ, name) 
    98100            self.connect(self.graphButton, SIGNAL("clicked()"), self.graph.saveToFile) 
     
    103105        self.optimizationDlg = self.vizrank  # for backward compatibility 
    104106 
    105         self.graph.normalizeExamples = ("radviz" in name.lower() or "sphereviz" in name.lower())       # ignore settings!! if we have radviz then normalize, otherwise not. 
     107        # ignore settings!! if we have radviz then normalize, otherwise not. 
     108        self.graph.normalizeExamples = ("radviz" in name_lower or "sphereviz" in name_lower) 
    106109 
    107110        #GUI 
     
    111114        self.GeneralTab = OWGUI.createTabPage(self.tabs, "Main") 
    112115        self.SettingsTab = OWGUI.createTabPage(self.tabs, "Settings", canScroll = 1) 
    113         if not "sphereviz" in name.lower(): 
     116        if not "3d" in name_lower: 
    114117            self.PerformanceTab = OWGUI.createTabPage(self.tabs, "Performance") 
    115118         
     
    122125 
    123126        # freeviz dialog 
    124         if "radviz" in name.lower() or "linear projection" in name.lower(): 
     127        if "radviz" in name_lower or "linear projection" in name_lower: 
    125128            self.freeVizDlg = FreeVizOptimization(self, self.signalManager, self.graph, name) 
    126129            self.wdChildDialogs.append(self.freeVizDlg) 
    127130            self.freeVizDlgButton = OWGUI.button(self.optimizationButtons, self, "FreeViz", callback = self.freeVizDlg.reshow, tooltip = "Opens FreeViz dialog, where the position of attribute anchors is optimized so that class separation is improved", debuggingEnabled = 0) 
    128             if "linear projection" in name.lower(): 
     131            if "linear projection" in name_lower: 
    129132                self.freeVizLearner = FreeVizLearner(self.freeVizDlg) 
    130133                self.send("FreeViz Learner", self.freeVizLearner) 
     
    155158        OWGUI.checkBox(box, self, 'graph.jitterContinuous', 'Jitter continuous attributes', callback = self.resetGraphData, tooltip = "Does jittering apply also on continuous attributes?") 
    156159 
    157         if not "sphereviz" in name.lower(): 
     160        if not "3d" in name_lower: 
    158161            box = OWGUI.widgetBox(self.SettingsTab, "Scaling Options") 
    159162            OWGUI.qwtHSlider(box, self, "graph.scaleFactor", label = 'Inflate points by: ', minValue=1.0, maxValue= 10.0, step=0.1, callback = self.updateGraph, tooltip="If points lie too much together you can expand their position to improve perception", maxWidth = 90) 
     
    163166        self.graph.gui.show_legend_check_box(box) 
    164167        bbox = OWGUI.widgetBox(box, orientation = "horizontal") 
    165         if "3d" in name.lower(): 
     168        if "3d" in name_lower: 
    166169            OWGUI.checkBox(bbox, self, 'graph.showValueLines', 'Show value lines  ', callback = self.graph.updateGL) 
    167170            OWGUI.qwtHSlider(bbox, self, 'graph.valueLineLength', minValue=1, maxValue=10, step=1, callback = self.graph.updateGL, showValueLabel = 0) 
     
    171174        OWGUI.checkBox(box, self, 'graph.useDifferentSymbols', 'Use different symbols', callback = self.updateGraph, tooltip = "Show different class values using different symbols") 
    172175        OWGUI.checkBox(box, self, 'graph.useDifferentColors', 'Use different colors', callback = self.updateGraph, tooltip = "Show different class values using different colors") 
    173         if not "sphereviz" in name.lower(): 
     176 
     177        if "sphereviz" in name_lower: 
     178            OWGUI.checkBox(box, self, 'graph.camera_in_center', 'Camera in center', callback = self.updateGraph, tooltip = "Look at the data from the center") 
     179        elif "3d" in name_lower: 
     180            pass 
     181        else: 
    174182            self.graph.gui.filled_symbols_check_box(box) 
    175183            wbox = OWGUI.widgetBox(box, orientation = "horizontal") 
     
    184192            box = OWGUI.widgetBox(smallWidget.widget, orientation = "horizontal") 
    185193            OWGUI.checkBox(box, self, 'graph.spaceBetweenCells', 'Show space between cells', callback = self.updateGraph) 
    186         else: 
    187             OWGUI.checkBox(box, self, 'graph.camera_in_center', 'Camera in center', callback = self.updateGraph, tooltip = "Look at the data from the center") 
    188194 
    189195        box = OWGUI.widgetBox(self.SettingsTab, "Colors", orientation = "horizontal") 
     
    202208        self.SettingsTab.layout().addStretch(100) 
    203209         
    204         if not "sphereviz" in name.lower(): 
     210        if not "3d" in name_lower: 
    205211            self.graph.gui.effects_box(self.PerformanceTab, ) 
    206212            self.PerformanceTab.layout().addStretch(100) 
Note: See TracChangeset for help on using the changeset viewer.