fit_principal_curves: fit principle curves

View source: R/fit_principal_curves.R

fit_principal_curvesR Documentation

fit principle curves

Description

fit principle curves

Usage

To use this for example,

 cluster_principal_curves <- dplyr::bind_cols(
   arrow::read_parquet("input/umap_embedding.parquet"),
   arrow::read_parquet("input/hbscan_clustering.parquet")) 
   MPStats::fit_principal_curves() 
   dplyr::arrange(princurve_order)

Arguments

cell_embedding

tibble::tibble with columns UMAP_1 UMAP_2 cluster_label

thin

number of samples for each cluster_label to fit curve to if false, use the full dataset

princurve_smoother

default: lowess (see princurve::principal_curve)

princurve_maxit

default: 300 (see princurve::principal_curve)

princurve_stretch

default: 0 (see princurve::principal_curve)

Value

tibble::tibble representing the principal curve for each cluster for each cluster UMAP_1 input embedding coordinate UMAP_2 input embedding coordiante cluster_label input cluster identifier princurve_1 UMAP_1 coordiante for the projection on to the principal curve princurve_2 UMAP_2 coordinate for the projection on to the principal curve princurve_labmda distance along the principal curve of the projection princurve_order order of projection along the principal curve


momeara/MPStats documentation built on July 19, 2022, 3:34 p.m.