Package: harmony 2.0.4

Ilya Korsunsky

harmony: Fast, Sensitive, and Accurate Integration of Single Cell Data

Implementation of the Harmony algorithm for single cell integration, described in Patikas, Yao, et al. <doi:10.64898/2026.03.16.711825>. Package includes a standalone Harmony function and interfaces to external frameworks.

Authors:Nikolaos Patikas [aut, ctb], Hongcheng Yao [aut, ctb], Ilya Korsunsky [cre, aut], Martin Hemberg [aut], Nghia Millard [aut], Jean Fan [aut, ctb], Kamil Slowikowski [aut, ctb], Miles Smith [ctb], Soumya Raychaudhuri [aut]

harmony_2.0.4.tar.gz
harmony_2.0.4.zip(r-4.7)harmony_2.0.4.zip(r-4.6)harmony_2.0.4.zip(r-4.5)
harmony_2.0.4.tgz(r-4.6-x86_64)harmony_2.0.4.tgz(r-4.6-arm64)harmony_2.0.4.tgz(r-4.5-x86_64)harmony_2.0.4.tgz(r-4.5-arm64)
harmony_2.0.4.tar.gz(r-4.7-arm64)harmony_2.0.4.tar.gz(r-4.7-x86_64)harmony_2.0.4.tar.gz(r-4.6-arm64)harmony_2.0.4.tar.gz(r-4.6-x86_64)
harmony_2.0.4.tgz(r-4.6-emscripten)
manual.pdf |manual.html
DESCRIPTION |NEWS
card.svg |card.png
harmony/json (API)

# Install 'harmony' in R:
install.packages('harmony', repos = c('https://immunogenomics.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/immunogenomics/harmony/issues

Pkgdown/docs site:https://pati-ni.github.io

Uses libs:
  • openblas– Optimized BLAS
  • c++– GNU Standard C++ Library v3
Datasets:
  • cell_lines - List of metadata table and scaled PCs matrix
  • cell_lines_small - Same as cell_lines but smaller (300 cells).
  • pbmc.ctrl - Gene expression data of control PBMC from Kang et al. 2017. This contains a sample of 1000 cells from that condition and is used for the Seurat Vignette.
  • pbmc.stim - Gene expression data of stimulated PBMC from Kang et al. 2017. This contains a sample of 1000 cells from that condition and is used for the Seurat Vignette.

On CRAN:

Conda:

algorithmdata-integrationscrna-seqopenblascpp

15.16 score 655 stars 9 packages 7.6k scripts 26k downloads 6 mentions 3 exports 32 dependencies

Last updated from:df19af23ae. Checks:12 OK, 1 ERROR. Indexed: yes.

TargetResultTimeFilesSyslog
linux-devel-arm64OK257
linux-devel-x86_64OK235
source / vignettesOK358
linux-release-arm64OK214
linux-release-x86_64OK293
macos-release-arm64OK195
macos-release-x86_64OK308
macos-oldrel-arm64OK181
macos-oldrel-x86_64OK330
windows-develOK216
windows-releaseERROR220
windows-oldrelOK219
wasm-releaseOK199

Exports:%>%harmony_optionsRunHarmony

Dependencies:clicowplotcpp11dplyrfarvergenericsggplot2gluegtableisobandlabelinglatticelifecyclemagrittrMatrixpillarpkgconfigR6RColorBrewerRcppRcppArmadilloRcppProgressRhpcBLASctlrlangS7scalestibbletidyselectutf8vctrsviridisLitewithr

Detailed Walkthrough of Harmony Algorithm
Motivation | Prerequisites | Cell line data | Initialize a Harmony object | L_2 scaling to induce cosine distance | Initial clustering | Evaluating initial cluster diversity | Maximum-diversity soft-clustering | Diverse cluster assignment | Cluster centroid estimation | Correction | Mixture of Experts model | Estimate MoE model parameters | Cell specific corrections | Multiple iterations of Harmony | Session info

Last update: 2026-05-05
Started: 2023-09-20

Quick start to Harmony
Introduction | Installation | Integrating cell line datasets from 10X | Next Steps | Interfacing to software packages | Detailed breakdown of the Harmony algorithm | Session Info

Last update: 2026-05-05
Started: 2019-04-16

Using harmony in Seurat
Introduction | Generating the dataset | Create SeuratObject | (Optional) Download original data | Running Harmony | Calculate PCA cell embeddings | Perform an integrated analysis using harmony | Using harmony embeddings for dimensionality reduction in Seurat | Perform clustering using the harmonized vectors of cells | TSNE dimensionality reduction | UMAP

Last update: 2026-05-05
Started: 2023-09-20