Skip to contents

Wrapper function into the Rust interface for PHATE using a precomputed kNN graph. Useful when iterating over diffusion parameters without repeating the neighbour search.

Usage

rs_phate_from_knn(embd, knn_data, n_dim, k, phate_params, seed, verbose)

Arguments

embd

Numerical matrix. The data to embed of shape samples x features.

knn_data

NearestNeighbours class from R.

n_dim

Integer. Number of PHATE dimensions to return. Currently only 2L is supported.

k

Integer. Number of nearest neighbours used during graph construction. Must match the k used to generate knn_data.

phate_params

Named list. Contains all key parameters for PHATE, see params_phate() and params_nn().

seed

Integer. Seed for reproducibility.

verbose

Boolean. Controls verbosity of the function.

Value

The PHATE embedding as a matrix of shape samples x n_dim.