R/03_metrics_clustering.R
calc_fmi.Rd
Integrated from scCluBench (Xu et al., AAAI 2026). Computes the geometric mean of pairwise cluster precision and recall.
calc_fmi(pred, truth)
Vector of predicted cluster labels.
Vector of ground truth cell type labels.
FMI score between 0 and 1.
pred <- factor(rep(c("A", "B"), each = 20)) truth <- factor(rep(c("A", "B"), each = 20)) calc_fmi(pred, truth) #> [1] 1