pyclustering.container.cftree.non_leaf_node Class Reference

Representation of clustering feature non-leaf node. More...

+ Inheritance diagram for pyclustering.container.cftree.non_leaf_node:
+ Collaboration diagram for pyclustering.container.cftree.non_leaf_node:

Public Member Functions

def successors (self)
 
def __init__ (self, feature, parent, successors)
 Create CF Non-leaf node. More...
 
def __repr__ (self)
 
def __str__ (self)
 
def insert_successor (self, successor)
 Insert successor to the node. More...
 
def merge (self, node)
 Merge non-leaf node to the current. More...
 
def get_farthest_successors (self, type_measurement)
 Find pair of farthest successors of the node in line with measurement type. More...
 
def get_nearest_successors (self, type_measurement)
 Find pair of nearest successors of the node in line with measurement type. More...
 
- Public Member Functions inherited from pyclustering.container.cftree.cfnode
def __init__ (self, feature, parent)
 Constructor of abstract CF node. More...
 
def __repr__ (self)
 
def __str__ (self)
 
def get_distance (self, node, type_measurement)
 Calculates distance between nodes in line with specified type measurement. More...
 

Public Attributes

 type
 Node type in CF tree that is CFNODE_NONLEAF for non leaf node. More...
 
- Public Attributes inherited from pyclustering.container.cftree.cfnode
 feature
 Clustering feature of the node. More...
 
 parent
 Pointer to the parent node (None for root). More...
 
 type
 Type node (leaf or non-leaf). More...
 

Detailed Description

Representation of clustering feature non-leaf node.

Definition at line 415 of file cftree.py.

Constructor & Destructor Documentation

◆ __init__()

def pyclustering.container.cftree.non_leaf_node.__init__ (   self,
  feature,
  parent,
  successors 
)

Create CF Non-leaf node.

Parameters
[in]feature(cfentry): Clustering feature of the created node.
[in]parent(non_leaf_node): Parent of the created node.
[in]successors(list): List of successors of the node.

Definition at line 430 of file cftree.py.

Member Function Documentation

◆ __repr__()

def pyclustering.container.cftree.non_leaf_node.__repr__ (   self)
Returns
(string) Representation of non-leaf node representation.

Definition at line 448 of file cftree.py.

Referenced by pyclustering.container.kdtree.node.__str__().

◆ __str__()

def pyclustering.container.cftree.non_leaf_node.__str__ (   self)
Returns
(string) String non-leaf representation.

Definition at line 456 of file cftree.py.

◆ get_farthest_successors()

def pyclustering.container.cftree.non_leaf_node.get_farthest_successors (   self,
  type_measurement 
)

Find pair of farthest successors of the node in line with measurement type.

Parameters
[in]type_measurement(measurement_type): Measurement type that is used for obtaining farthest successors.
Returns
(list) Pair of farthest successors represented by list [cfnode1, cfnode2].

Definition at line 493 of file cftree.py.

◆ get_nearest_successors()

def pyclustering.container.cftree.non_leaf_node.get_nearest_successors (   self,
  type_measurement 
)

Find pair of nearest successors of the node in line with measurement type.

Parameters
[in]type_measurement(measurement_type): Measurement type that is used for obtaining nearest successors.
Returns
(list) Pair of nearest successors represented by list.

Definition at line 522 of file cftree.py.

◆ insert_successor()

def pyclustering.container.cftree.non_leaf_node.insert_successor (   self,
  successor 
)

Insert successor to the node.

Parameters
[in]successor(cfnode): Successor for adding.

Definition at line 464 of file cftree.py.

◆ merge()

def pyclustering.container.cftree.non_leaf_node.merge (   self,
  node 
)

Merge non-leaf node to the current.

Parameters
[in]node(non_leaf_node): Non-leaf node that should be merged with current.

Definition at line 478 of file cftree.py.

◆ successors()

Member Data Documentation

◆ type

pyclustering.container.cftree.non_leaf_node.type

Node type in CF tree that is CFNODE_NONLEAF for non leaf node.

Definition at line 443 of file cftree.py.


The documentation for this class was generated from the following file: