<commit_before>"""Run Diffusion maps using the adaptive anisotropic kernel
"""

from .. import logging as logg

def palantir( adata ):
    """
    Run Diffusion maps using the adaptive anisotropic kernel [Setty27]_.

    Palantir is an algorithm to align cells along differentiation trajectories.
    Palantir models differentiation as a stochastic process where stem cells
    differentiate to terminally differentiated cells by a series of steps through
    a low dimensional phenotypic manifold. Palantir effectively captures the
    continuity in cell states and the stochasticity in cell fate determination.
    Palantir has been designed to work with multidimensional single cell data
    from diverse technologies such as Mass cytometry and single cell RNA-seq.

    .. note::
        More information and bug reports `here <https://github.com/dpeerlab/Palantir>`__.

    :param adata: :class:`~anndata.AnnData`, or Dataframe of cells X genes

    :param normalize: `bool` (default: `False`), property setter passed to
                      palantir to normalize using palantir method,
                      `palantir.preprocess.normalize_counts`

    :param log_transform: `bool` (default: `False`), property setter passed to
                          palantir. Some datasets show better signal in the log
                          scale. Applied using `palantir.preprocess.log_transform`
<commit_msg>Update _palantir.py<commit_after>"""Run Diffusion maps using the adaptive anisotropic kernel
"""

from .. import logging as logg


def palantir( adata ):
    """
    Run Diffusion maps using the adaptive anisotropic kernel [Setty27]_.

    Palantir is an algorithm to align cells along differentiation trajectories.
    Palantir models differentiation as a stochastic process where stem cells
    differentiate to terminally differentiated cells by a series of steps through
    a low dimensional phenotypic manifold. Palantir effectively captures the
    continuity in cell states and the stochasticity in cell fate determination.
    Palantir has been designed to work with multidimensional single cell data
    from diverse technologies such as Mass cytometry and single cell RNA-seq.

    .. note::
        More information and bug reports `here <https://github.com/dpeerlab/Palantir>`__.

    :param adata: :class:`~anndata.AnnData`, or Dataframe of cells X genes

    :param normalize: `bool` (default: `False`), property setter passed to
                      palantir to normalize using palantir method,
                      `palantir.preprocess.normalize_counts`

    :param log_transform: `bool` (default: `False`), property setter passed to
                          palantir. Some datasets show better signal in the log
                          scale. Applied using `palantir.preprocess.log_transform`

{'fraction_non_alphanumeric': 0.05699115044247788, 'fraction_numerical': 0.001415929203539823, 'mean_word_length': 3.0838150289017343, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7525682', 'n_tokens_mistral': 738, 'n_tokens_neox': 660, 'n_words': 307}