Changeset 10330:616584f3fd52 in orange


Ignore:
Timestamp:
02/21/12 15:56:36 (2 years ago)
Author:
Ales Erjavec <ales.erjavec@…>
Branch:
default
Message:

Removed old unneeded code (for old mult-label domains) from earth module.

Location:
Orange/regression
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • Orange/regression/earth.py

    r10328 r10330  
    468468""" 
    469469 
    470 def is_label_attr(attr): 
    471     """ Is attribute a label. 
    472     """ 
    473     return attr.attributes.has_key("label") 
    474      
    475 def data_label_indices(domain): 
    476     """ Return the indices of label attributes in data. 
    477     """ 
    478     return numpy.where(data_label_mask(domain))[0] 
    479  
    480 def data_label_mask(domain): 
    481     """ Return an array of booleans indicating whether a variable in the 
    482     domain is a label. 
    483     """ 
    484     is_label = map(is_label_attr, domain.variables) 
    485     if domain.class_var: 
    486         is_label[-1] = True 
    487     return numpy.array(is_label, dtype=bool) 
    488470 
    489471""" 
  • Orange/regression/pls.py

    r10294 r10330  
    7979 
    8080from Orange.regression import base 
    81 from Orange.regression.earth import data_label_mask 
    8281from numpy import dot, zeros 
    8382from numpy import linalg 
Note: See TracChangeset for help on using the changeset viewer.