---
name: "mlpack_tree_MRKDStatistic"
section: "3"
platform: "linux"
package: "mlpack-doc"
version: "1.0.10-1"
release: "Debian 8 (Jessie)"
platforms: ["linux"]
url: "https://new.carta.tech/mlpack_tree_MRKDStatistic"
---

# mlpack\_tree\_MRKDStatistic(3)

Statistic for multi-resolution kd-trees.

## NAME

mlpack::tree::MRKDStatistic -

Statistic for multi-resolution kd-trees.

## SYNOPSIS

### Public Member Functions

**MRKDStatistic** ()\
 *Initialize an empty statistic.*  template\<typename TreeType \> **MRKDStatistic** (const TreeType &)\
 *This constructor is called when a node is finished initializing.*  size\_t **Begin** () const \
 *Get the index of the initial item in the dataset.*  size\_t & **Begin** ()\
 *Modify the index of the initial item in the dataset.*  const arma::colvec & **CenterOfMass** () const \
 *Get the center of mass.*  arma::colvec & **CenterOfMass** ()\
 *Modify the center of mass.*  size\_t **Count** () const \
 *Get the number of items in the dataset.*  size\_t & **Count** ()\
 *Modify the number of items in the dataset.*  size\_t **DominatingCentroid** () const \
 *Get the index of the dominating centroid.*  size\_t & **DominatingCentroid** ()\
 *Modify the index of the dominating centroid.*  std::string **ToString** () const \
 *Returns a string representation of this object.*  const std::vector\< size\_t \> & **Whitelist** () const \
 *Access the whitelist.*  std::vector\< size\_t \> & **Whitelist** ()\
 *Modify the whitelist.*

### Private Attributes

size\_t **begin**\
 *The initial item in the dataset, so we don't have to make a copy.*  arma::colvec **centerOfMass**\
 *The center of mass for this dataset.*  size\_t **count**\
 *The number of items in the dataset.*  const arma::mat \* **dataset**\
 *The data points this object contains.*  size\_t **dominatingCentroid**\
 *The index of the dominating centroid of the associated hyperrectangle.*  bool **isWhitelistValid**\
 *Whether or not the whitelist is valid.*  const **MRKDStatistic** \* **leftStat**\
 *The left child.*  const **MRKDStatistic** \* **parentStat**\
 *A link to the parent node; NULL if this is the root.*  const **MRKDStatistic** \* **rightStat**\
 *The right child.*  double **sumOfSquaredNorms**\
 *The sum of the squared Euclidean norms for this dataset.*  std::vector\< size\_t \> **whitelist**\
 *The list of centroids that cannot own this hyperrectangle.*

## Detailed Description

Statistic for multi-resolution kd-trees.

Definition at line 33 of file mrkd\_statistic.hpp.

## Constructor & Destructor Documentation

### mlpack::tree::MRKDStatistic::MRKDStatistic ()

Initialize an empty statistic.

### template\<typename TreeType \> mlpack::tree::MRKDStatistic::MRKDStatistic (const TreeType &)

This constructor is called when a node is finished initializing.

**Parameters:**

*node* The node that has been finished.

## Member Function Documentation

### size\_t mlpack::tree::MRKDStatistic::Begin () const` [inline]`

Get the index of the initial item in the dataset.

Definition at line 53 of file mrkd\_statistic.hpp.

References begin.

### size\_t& mlpack::tree::MRKDStatistic::Begin ()` [inline]`

Modify the index of the initial item in the dataset.

Definition at line 55 of file mrkd\_statistic.hpp.

References begin.

### const arma::colvec& mlpack::tree::MRKDStatistic::CenterOfMass () const` [inline]`

Get the center of mass.

Definition at line 63 of file mrkd\_statistic.hpp.

References centerOfMass.

### arma::colvec& mlpack::tree::MRKDStatistic::CenterOfMass ()` [inline]`

Modify the center of mass.

Definition at line 65 of file mrkd\_statistic.hpp.

References centerOfMass.

### size\_t mlpack::tree::MRKDStatistic::Count () const` [inline]`

Get the number of items in the dataset.

Definition at line 58 of file mrkd\_statistic.hpp.

References count.

### size\_t& mlpack::tree::MRKDStatistic::Count ()` [inline]`

Modify the number of items in the dataset.

Definition at line 60 of file mrkd\_statistic.hpp.

References count.

### size\_t mlpack::tree::MRKDStatistic::DominatingCentroid () const` [inline]`

Get the index of the dominating centroid.

Definition at line 68 of file mrkd\_statistic.hpp.

References dominatingCentroid.

### size\_t& mlpack::tree::MRKDStatistic::DominatingCentroid ()` [inline]`

Modify the index of the dominating centroid.

Definition at line 70 of file mrkd\_statistic.hpp.

References dominatingCentroid.

### std::string mlpack::tree::MRKDStatistic::ToString () const

Returns a string representation of this object.

### const std::vector\<size\_t\>& mlpack::tree::MRKDStatistic::Whitelist () const` [inline]`

Access the whitelist.

Definition at line 73 of file mrkd\_statistic.hpp.

References whitelist.

### std::vector\<size\_t\>& mlpack::tree::MRKDStatistic::Whitelist ()` [inline]`

Modify the whitelist.

Definition at line 75 of file mrkd\_statistic.hpp.

References whitelist.

## Member Data Documentation

### size\_t mlpack::tree::MRKDStatistic::begin` [private]`

The initial item in the dataset, so we don't have to make a copy.

Definition at line 81 of file mrkd\_statistic.hpp.

Referenced by Begin().

### arma::colvec mlpack::tree::MRKDStatistic::centerOfMass` [private]`

The center of mass for this dataset.

Definition at line 93 of file mrkd\_statistic.hpp.

Referenced by CenterOfMass().

### size\_t mlpack::tree::MRKDStatistic::count` [private]`

The number of items in the dataset.

Definition at line 83 of file mrkd\_statistic.hpp.

Referenced by Count().

### const arma::mat\* mlpack::tree::MRKDStatistic::dataset` [private]`

The data points this object contains.

Definition at line 79 of file mrkd\_statistic.hpp.

### size\_t mlpack::tree::MRKDStatistic::dominatingCentroid` [private]`

The index of the dominating centroid of the associated hyperrectangle.

Definition at line 99 of file mrkd\_statistic.hpp.

Referenced by DominatingCentroid().

### bool mlpack::tree::MRKDStatistic::isWhitelistValid` [private]`

Whether or not the whitelist is valid.

Definition at line 104 of file mrkd\_statistic.hpp.

### const MRKDStatistic\* mlpack::tree::MRKDStatistic::leftStat` [private]`

The left child.

Definition at line 85 of file mrkd\_statistic.hpp.

### const MRKDStatistic\* mlpack::tree::MRKDStatistic::parentStat` [private]`

A link to the parent node; NULL if this is the root.

Definition at line 89 of file mrkd\_statistic.hpp.

### const MRKDStatistic\* mlpack::tree::MRKDStatistic::rightStat` [private]`

The right child.

Definition at line 87 of file mrkd\_statistic.hpp.

### double mlpack::tree::MRKDStatistic::sumOfSquaredNorms` [private]`

The sum of the squared Euclidean norms for this dataset.

Definition at line 95 of file mrkd\_statistic.hpp.

### std::vector\<size\_t\> mlpack::tree::MRKDStatistic::whitelist` [private]`

The list of centroids that cannot own this hyperrectangle.

Definition at line 102 of file mrkd\_statistic.hpp.

Referenced by Whitelist().

## Author

Generated automatically by Doxygen for MLPACK from the source code.
