scanpy.external.tl.palantir_results

scanpy.external.tl.palantir_results#

scanpy.external.tl.palantir_results(adata, early_cell, *, ms_data='X_palantir_multiscale', terminal_states=None, knn=30, num_waypoints=1200, n_jobs=-1, scale_components=True, use_early_cell_as_start=False, max_iterations=25)[source]#

Running Palantir

A convenience function that wraps palantir.core.run_palantir to compute branch probabilities and waypoints.

Parameters:
adata AnnData

An AnnData object.

early_cell str

Start cell for pseudotime construction.

ms_data str (default: 'X_palantir_multiscale')

Palantir multi scale data matrix,

terminal_states list | None (default: None)

List of user defined terminal states

knn int (default: 30)

Number of nearest neighbors for graph construction.

num_waypoints int (default: 1200)

Number of waypoints to sample.

n_jobs int (default: -1)

Number of jobs for parallel processing.

scale_components bool (default: True)

Transform features by scaling each feature to a given range. Consult the documentation for sklearn.preprocessing.minmax_scale.

use_early_cell_as_start bool (default: False)

Use early_cell as start_cell, instead of determining it from the boundary cells closest to the defined early_cell.

max_iterations int (default: 25)

Maximum number of iterations for pseudotime convergence.

Return type:

AnnData | None

Returns:

PResults object with pseudotime, entropy, branch probabilities and waypoints.