Skip to content

Performing Integration with RNA + ADT + Cite-seq data #9827

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
jules-samaran opened this issue Apr 20, 2025 · 0 comments
Open

Performing Integration with RNA + ADT + Cite-seq data #9827

jules-samaran opened this issue Apr 20, 2025 · 0 comments

Comments

@jules-samaran
Copy link

Dear Seurat team,

For a benchmark, I've recently tried to apply your bridge integration approach to a cite-seq dataset where a fraction of samples are used as a paired bridge while the rest of the cells are treated as unpaired and RNA and ADT modalities are considered separately. The Bridge integration vignette only presents the RNA-ATAC integration case and while thislink provides such an example, I haven't managed to obtain satisfactory results in terms of cell type annotation transfer even though I'm only using data from one single batch of the Neurips 2021 Open problems dataset which shouldn't be too hard.
Could you tell me if there's something wrong with the way I applied the method?

`
mod1 <- "RNA"
mod2 <- "ADT"
obj.mod1 <- MuDataSeurat::ReadH5AD(paste0(save.path, "/mod1.h5ad"))
obj.mod2 <- MuDataSeurat::ReadH5AD(paste0(save.path, "/mod2.h5ad"))
obj.bridge <- MuDataSeurat::ReadH5MU(paste0(save.path, "/bridge.h5mu"))

These matrices only contain raw counts and the RNA data should have celltypes, 4000 hvg have already been selected for the RNA data

new_mod1_names = paste0(colnames(obj.mod1), "|", mod1)
new_mod2_names = paste0(colnames(obj.mod2), "|", mod2)
obj.mod1 <- RenameCells(
obj.mod1,
new.names = new_mod1_names
)
obj.mod2 <- RenameCells(
obj.mod2,
new.names = new_mod2_names
)

preprocessing the bridge data

DefaultAssay(obj.bridge) <- mod1
obj.bridge <- SCTransform(obj.bridge, verbose = FALSE)
VariableFeatures(obj.bridge) <- rownames(obj.bridge)
VariableFeatures(obj.mod1) <- rownames(obj.mod1)

DefaultAssay(obj.bridge) <- mod2
VariableFeatures(obj.bridge) <- rownames(obj.bridge)
obj.bridge <- NormalizeData(obj.bridge, normalization.method = "CLR", margin = 2, assay = mod2)
obj.bridge <- ScaleData(obj.bridge, verbose=FALSE)

preprocess the Rna unpaired data

obj.mod1 <- SCTransform(obj.mod1, verbose = FALSE) %>%
RunPCA() %>%
RunUMAP(dims = 1:50, return.model = TRUE)
dims.mod1 <- 1:50

preprocess the Adt unpaired data

obj.mod2 <- RenameAssays(obj.mod2, RNA=mod2)
VariableFeatures(obj.mod2) <- rownames(obj.mod2)
obj.mod2 <- NormalizeData(obj.mod2, normalization.method = "CLR", margin = 2, assay = mod2)
obj.mod2 <- ScaleData(obj.mod2, verbose=FALSE)
obj.mod2 <- RunPCA(obj.mod2, verbose = FALSE)
mod2.reduction <- "pcaproject"
dims.mod2 <- 1:50

Obtain integrated embeddings

DefaultAssay(obj.bridge) <- mod1
DefaultAssay(obj.mod1) <- "SCT"
obj.mod1.ext <- PrepareBridgeReference(
reference = obj.mod1, bridge = obj.bridge,
bridge.ref.assay = mod1, bridge.query.assay = mod2,
reference.reduction = "pca", reference.dims = dims.mod1,
normalization.method = "SCT")

bridge.integration.anchor <- FindBridgeIntegrationAnchors(
extended.reference = obj.mod1.ext, query = obj.mod2,
reduction = mod2.reduction, dims = dims.mod2)
obj.integrate <- IntegrateEmbeddings(anchorset = bridge.integration.anchor, reference = obj.mod1.ext, query = obj.mod2)

Transfer celltype annotations

bridge.transfer.anchor <- FindBridgeTransferAnchors(
extended.reference = obj.mod1.ext, query = obj.mod2,
reduction = mod2.reduction, dims = dims.mod2)

obj.mod2 <- MapQuery(
anchorset = bridge.transfer.anchor, reference = obj.mod1.ext,
query = obj.mod2,
refdata = list(
celltype = "celltype"),
reduction.model = "umap")
`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant