View source: R/AnnoyIndex-class.R
AnnoyIndex | R Documentation |
A class to hold indexing structures for the Annoy algorithm for approximate nearest neighbor identification.
AnnoyIndex(data, path, search.mult = 50, NAMES = NULL, distance = "Euclidean")
data |
A numeric matrix with data points in columns and dimensions in rows. |
path |
A string specifying the path to the index file. |
search.mult |
Numeric scalar, multiplier for the number of points to search. |
NAMES |
A character vector of sample names or |
distance |
A string specifying the distance metric to use. |
The AnnoyIndex class holds the indexing structure required to run the Annoy algorithm.
Users should never need to call the constructor explicitly, but should generate instances of AnnoyIndex classes with buildAnnoy
.
Users can get values from an AnnoyIndex object with the usual [[
syntax.
All parameters listed in the constructor can be extracted in this manner.
An instance of the AnnoyIndex class.
Aaron Lun
buildAnnoy
, for the index construction.
BiocNeighborIndex, for the parent class and its available methods.
example(buildAnnoy)
out[['path']]
bndistance(out)
str(bndata(out))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.