![]() |
pyclustering
0.10.1
pyclustring is a Python, C++ data mining library.
|
CLIQUE block contains information about its logical location in grid, spatial location in data space and points that are covered by the block. More...
Public Member Functions | |
| def | __init__ (self, logical_location=None, spatial_location=None, points=None, visited=False) |
| Initializes CLIQUE block. More... | |
| def | __str__ (self) |
| Returns string representation of the block using its logical location in CLIQUE grid. | |
| def | __repr__ (self) |
| Returns string representation of the block using its logical location in CLIQUE grid. | |
| def | logical_location (self) |
| Logical location is represented by coordinates in CLIQUE grid, for example, in case of 2x2 grid blocks may have following coordinates: [0, 0], [0, 1], [1, 0], [1, 1]. More... | |
| def | logical_location (self, location) |
| Assign logical location to CLIQUE block. More... | |
| def | spatial_location (self) |
| Spatial location is represented by real data space coordinates. More... | |
| def | spatial_location (self, location) |
| Assign spatial location to CLIQUE block. More... | |
| def | dimensions (self) |
| Amount of dimensions where CLIQUE block is located. More... | |
| def | points (self) |
| Points that belong to the CLIQUE block. More... | |
| def | visited (self) |
| Defines whether block is visited during cluster analysis. More... | |
| def | visited (self, visited) |
| Marks or unmarks block as a visited. More... | |
| def | capture_points (self, data, point_availability) |
| Finds points that belong to this block using availability map to reduce computational complexity by checking whether the point belongs to the block. More... | |
| def | get_location_neighbors (self, edge) |
| Forms list of logical location of each neighbor for this particular CLIQUE block. More... | |
CLIQUE block contains information about its logical location in grid, spatial location in data space and points that are covered by the block.
| def pyclustering.cluster.clique.clique_block.__init__ | ( | self, | |
logical_location = None, |
|||
spatial_location = None, |
|||
points = None, |
|||
visited = False |
|||
| ) |
Initializes CLIQUE block.
| [in] | logical_location | (list): Logical location of the block in CLIQUE grid. |
| [in] | spatial_location | (spatial_block): Spatial location in data space. |
| [in] | points | (array_like): Points that belong to this block (can be obtained by method 'capture_points', this parameter is used by CLIQUE in case of processing by C++ implementation when clustering result are passed back to Python code. |
| [in] | visited | (bool): Marks if block is visited during clustering process. |
| def pyclustering.cluster.clique.clique_block.capture_points | ( | self, | |
| data, | |||
| point_availability | |||
| ) |
Finds points that belong to this block using availability map to reduce computational complexity by checking whether the point belongs to the block.
Algorithm complexity of this method is O(n).
| [in] | data | (array_like): Data where points are represented as coordinates. |
| [in] | point_availability | (array_like): Contains boolean values that denote whether point is already belong to another CLIQUE block. |
| def pyclustering.cluster.clique.clique_block.dimensions | ( | self | ) |
| def pyclustering.cluster.clique.clique_block.get_location_neighbors | ( | self, | |
| edge | |||
| ) |
Forms list of logical location of each neighbor for this particular CLIQUE block.
| [in] | edge | (uint): Amount of intervals in each dimension that is used for clustering process. |
| def pyclustering.cluster.clique.clique_block.logical_location | ( | self | ) |
Logical location is represented by coordinates in CLIQUE grid, for example, in case of 2x2 grid blocks may have following coordinates: [0, 0], [0, 1], [1, 0], [1, 1].
Definition at line 245 of file clique.py.
Referenced by pyclustering.cluster.clique.clique_block.logical_location().
| def pyclustering.cluster.clique.clique_block.logical_location | ( | self, | |
| location | |||
| ) |
| def pyclustering.cluster.clique.clique_block.points | ( | self | ) |
Points that belong to the CLIQUE block.
Points are represented by indexes that correspond to points in input data space.
| def pyclustering.cluster.clique.clique_block.spatial_location | ( | self | ) |
Spatial location is represented by real data space coordinates.
Definition at line 265 of file clique.py.
Referenced by pyclustering.cluster.clique.clique_block.spatial_location().
| def pyclustering.cluster.clique.clique_block.spatial_location | ( | self, | |
| location | |||
| ) |
Assign spatial location to CLIQUE block.
| [in] | location | (spatial_block): New spatial location of the block. |
| def pyclustering.cluster.clique.clique_block.visited | ( | self | ) |
Defines whether block is visited during cluster analysis.
If cluster analysis has not been performed then value will False.
Definition at line 306 of file clique.py.
Referenced by pyclustering.cluster.clique.clique_block.visited().
| def pyclustering.cluster.clique.clique_block.visited | ( | self, | |
| visited | |||
| ) |