phlower.tl.construct_trucated_delaunay

phlower.tl.construct_trucated_delaunay(adata: AnnData, graph_name: str | None = None, layout_name: str | None = None, trunc_quantile: float = 0.75, trunc_times: float = 3, iscopy: bool = False)
Function for only constructing delaunay graph from a layout without creating holes
  1. triangulate using the layout given

  2. remove too long distance edges by trunc_quantile * trunc_times

Parameters

adata: AnnData

AnnData object

graph_name: str

graph name in adata.uns

layout_name: str

layout name in adata.obsm

trunc_quantile: float

quantile for truncating delaunay edges

trunc_times: float

times for truncating delaunay edges

is_copy: bool

whether to return a copy of adata