Skip to contents

Summarizes top features per cluster from expression data or selected result columns, with optional z-score scaling. Features are ranked by their mean (or z-scored mean) within each cluster, and the top topn are returned.

Usage

get_cluster_features(
  spe,
  clusterid = NULL,
  topn = 3,
  spmethod = NULL,
  zscore = TRUE
)

Arguments

spe

SpatialExperiment with clustering results.

clusterid

Name of the column containing cluster labels.

topn

Number of top features to return per cluster.

spmethod

Method used for clustering (e.g., dorothea, collectri, progeny, expression, or a deconvolution method token).

zscore

Logical; z-score scale features before ranking.