Click or drag to resize
Accord.NET (logo)

KDTree Class

Convenience class for k-dimensional tree static methods. To create a new KDTree, specify the generic parameter as in KDTreeT.
Inheritance Hierarchy
SystemObject
  Accord.CollectionsBinaryTreeKDTreeNode
    Accord.CollectionsKDTreeBaseKDTreeNode
      Accord.CollectionsKDTree

Namespace:  Accord.Collections
Assembly:  Accord.MachineLearning (in Accord.MachineLearning.dll) Version: 3.8.0
Syntax
[SerializableAttribute]
public class KDTree : KDTreeBase<KDTreeNode>
Request Example View Source

The KDTree type exposes the following members.

Constructors
  NameDescription
Public methodKDTree(Int32)
Creates a new KDTree.
Public methodKDTree(Int32, KDTreeNode)
Creates a new KDTree.
Public methodKDTree(Int32, KDTreeNode, Int32, Int32)
Creates a new KDTree.
Top
Properties
Methods
  NameDescription
Public methodAdd
Adds a new point to this tree.
Protected methodAddNode
Inserts a value into the tree at the desired position.
(Inherited from KDTreeBaseTNode.)
Public methodApproximateNearest(Double, Double)
Retrieves a percentage of nearest points to a given point.
(Inherited from KDTreeBaseTNode.)
Public methodApproximateNearest(Double, Int32)
Retrieves a fixed number of nearest points to a given point.
(Inherited from KDTreeBaseTNode.)
Public methodApproximateNearest(Double, Double, Double)
Retrieves a percentage of nearest points to a given point.
(Inherited from KDTreeBaseTNode.)
Public methodApproximateNearest(Double, Int32, Double)
Retrieves a fixed percentage of nearest points to a given point.
(Inherited from KDTreeBaseTNode.)
Public methodApproximateNearest(Double, Int32, Int32)
Retrieves a fixed number of nearest points to a given point.
(Inherited from KDTreeBaseTNode.)
Public methodClear
Removes all nodes from this tree.
(Inherited from KDTreeBaseTNode.)
Public methodCopyTo
Copies the entire tree to a compatible one-dimensional Array, starting at the specified arrayIndex of the array.
(Inherited from KDTreeBaseTNode.)
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodStatic memberFromData(Double, Boolean)
Creates a new k-dimensional tree from the given points.
Public methodStatic memberFromData(Double, IMetricDouble, Boolean)
Creates a new k-dimensional tree from the given points.
Public methodStatic memberFromDataT(Double, Boolean)
Creates a new k-dimensional tree from the given points.
Public methodStatic memberFromDataT(Double, IMetricDouble, Boolean)
Creates a new k-dimensional tree from the given points.
Public methodStatic memberFromDataT(Double, T, Boolean)
Creates a new k-dimensional tree from the given points.
Public methodStatic memberFromDataT(Double, T, IMetricDouble, Boolean)
Creates a new k-dimensional tree from the given points.
Public methodGetEnumerator
Returns an enumerator that iterates through the tree.
(Inherited from BinaryTreeTNode.)
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetNodesInsideRegion
Retrieves a list of all points inside a given region.
(Inherited from KDTreeBaseTNode.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodNearest(Double)
Retrieves the nearest point to a given point.
(Inherited from KDTreeBaseTNode.)
Public methodNearest(Double, Double)
Retrieves the nearest points to a given point within a given radius.
(Inherited from KDTreeBaseTNode.)
Public methodNearest(Double, Double)
Retrieves the nearest point to a given point.
(Inherited from KDTreeBaseTNode.)
Public methodNearest(Double, Int32)
Retrieves a fixed number of nearest points to a given point.
(Inherited from KDTreeBaseTNode.)
Public methodNearest(Double, Double, Int32)
Retrieves the nearest points to a given point within a given radius.
(Inherited from KDTreeBaseTNode.)
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Public methodTraverse
Traverse the tree using a tree traversal method. Can be iterated with a foreach loop.
(Inherited from BinaryTreeTNode.)
Top
Extension Methods
  NameDescription
Public Extension MethodHasMethod
Checks whether an object implements a method with the given name.
(Defined by ExtensionMethods.)
Public Extension MethodIsEqual
Compares two objects for equality, performing an elementwise comparison if the elements are vectors or matrices.
(Defined by Matrix.)
Public Extension MethodTo(Type)Overloaded.
Converts an object into another type, irrespective of whether the conversion can be done at compile time or not. This can be used to convert generic types to numeric types during runtime.
(Defined by ExtensionMethods.)
Public Extension MethodToTOverloaded.
Converts an object into another type, irrespective of whether the conversion can be done at compile time or not. This can be used to convert generic types to numeric types during runtime.
(Defined by ExtensionMethods.)
Top
Remarks
See Also