OpenMS
2.8.0
|
basic data structure for clustering More...
#include <OpenMS/COMPARISON/CLUSTERING/GridBasedCluster.h>
Public Types | |
typedef DPosition< 2 > | Point |
typedef DBoundingBox< 2 > | Rectangle |
Public Member Functions | |
GridBasedCluster (const Point ¢re, const Rectangle &bounding_box, const std::vector< int > &point_indices, const int &property_A, const std::vector< int > &properties_B) | |
initialises all data structures More... | |
GridBasedCluster (const Point ¢re, const Rectangle &bounding_box, const std::vector< int > &point_indices) | |
initialises all data structures More... | |
const Point & | getCentre () const |
returns cluster centre More... | |
const Rectangle & | getBoundingBox () const |
returns bounding box More... | |
const std::vector< int > & | getPoints () const |
returns indices of points in cluster More... | |
int | getPropertyA () const |
returns property A More... | |
const std::vector< int > & | getPropertiesB () const |
returns properties B of all points More... | |
bool | operator< (const GridBasedCluster &other) const |
operators for comparisons More... | |
bool | operator> (const GridBasedCluster &other) const |
bool | operator== (const GridBasedCluster &other) const |
Private Attributes | |
Point | centre_ |
centre of the cluster More... | |
Rectangle | bounding_box_ |
bounding box of the cluster i.e. (min,max) in x and y direction More... | |
std::vector< int > | point_indices_ |
set of indices referencing the points in the cluster More... | |
int | property_A_ |
properties A and B Each point in a cluster can (optionally) possess two properties A and B. For two points to be in the same cluster, they need to have the same property A, e.g. the same charge. For two points to be in the same cluster, they need to have different properties B, e.g. originate from two different maps. -1 means properties are not set. More... | |
std::vector< int > | properties_B_ |
basic data structure for clustering
typedef DBoundingBox<2> Rectangle |
bounding box of a cluster
GridBasedCluster | ( | const Point & | centre, |
const Rectangle & | bounding_box, | ||
const std::vector< int > & | point_indices, | ||
const int & | property_A, | ||
const std::vector< int > & | properties_B | ||
) |
initialises all data structures
GridBasedCluster | ( | const Point & | centre, |
const Rectangle & | bounding_box, | ||
const std::vector< int > & | point_indices | ||
) |
initialises all data structures
const Rectangle& getBoundingBox | ( | ) | const |
returns bounding box
Referenced by GridBasedClustering< Metric >::cluster().
const Point& getCentre | ( | ) | const |
returns cluster centre
Referenced by GridBasedClustering< Metric >::cluster(), and GridBasedClustering< Metric >::findNearestNeighbour_().
const std::vector<int>& getPoints | ( | ) | const |
returns indices of points in cluster
Referenced by GridBasedClustering< Metric >::cluster().
const std::vector<int>& getPropertiesB | ( | ) | const |
returns properties B of all points
Referenced by GridBasedClustering< Metric >::cluster(), and GridBasedClustering< Metric >::mergeVeto_().
int getPropertyA | ( | ) | const |
returns property A
Referenced by GridBasedClustering< Metric >::cluster(), and GridBasedClustering< Metric >::mergeVeto_().
bool operator< | ( | const GridBasedCluster & | other | ) | const |
operators for comparisons
bool operator== | ( | const GridBasedCluster & | other | ) | const |
bool operator> | ( | const GridBasedCluster & | other | ) | const |
|
private |
bounding box of the cluster i.e. (min,max) in x and y direction
|
private |
centre of the cluster
|
private |
set of indices referencing the points in the cluster
|
private |
|
private |
properties A and B Each point in a cluster can (optionally) possess two properties A and B. For two points to be in the same cluster, they need to have the same property A, e.g. the same charge. For two points to be in the same cluster, they need to have different properties B, e.g. originate from two different maps. -1 means properties are not set.