Ignore:
Timestamp:
02/07/12 13:16:54 (2 years ago)
Author:
markotoplak
Branch:
default
Message:

data.variable -> feature

File:
1 edited

Legend:

Unmodified
Added
Removed
  • Orange/classification/svm/__init__.py

    r9671 r9919  
    294294        # Fix the svm_type parameter if we have a class_var/svm_type mismatch 
    295295        if self.svm_type in [0,1] and \ 
    296             isinstance(class_var, Orange.data.variable.Continuous): 
     296            isinstance(class_var, Orange.feature.Continuous): 
    297297            self.svm_type += 3 
    298298            #raise AttributeError, "Cannot learn a discrete classifier from non descrete class data. Use EPSILON_SVR or NU_SVR for regression" 
    299299        if self.svm_type in [3,4] and \ 
    300             isinstance(class_var, Orange.data.variable.Discrete): 
     300            isinstance(class_var, Orange.feature.Discrete): 
    301301            self.svm_type -= 3 
    302302            #raise AttributeError, "Cannot do regression on descrete class data. Use C_SVC or NU_SVC for classification" 
     
    647647            for sv_ind in range(*sv_ranges[i]): 
    648648                attributes = SVs.domain.attributes + \ 
    649                 SVs[sv_ind].getmetas(False, Orange.data.variable.Variable).keys() 
     649                SVs[sv_ind].getmetas(False, Orange.feature.Descriptor).keys() 
    650650                for attr in attributes: 
    651651                    if attr.varType == Orange.data.Type.Continuous: 
     
    655655            for sv_ind in range(*sv_ranges[j]): 
    656656                attributes = SVs.domain.attributes + \ 
    657                 SVs[sv_ind].getmetas(False, Orange.data.variable.Variable).keys() 
     657                SVs[sv_ind].getmetas(False, Orange.feature.Descriptor).keys() 
    658658                for attr in attributes: 
    659659                    if attr.varType==Orange.data.Type.Continuous: 
Note: See TracChangeset for help on using the changeset viewer.