MarcElosua / SPOTlight

Spatial Transcriptomics Capture Location Deconvolution
https://marcelosua.github.io/SPOTlight
GNU General Public License v3.0
159 stars 25 forks source link

assay %in% SeuratObject::Assays(x) is not TRUE #111

Open 628511miao opened 8 months ago

628511miao commented 8 months ago

I am performing SPOTlight and I am getting this error:

res <- SPOTlight(

axiba053 commented 6 months ago

+1

axiba053 commented 6 months ago

This is the software version, data structure, running code and error message. What is the cause? How to solve it? Thank you very much!

> packageVersion('SPOTlight')
[1] ‘1.7.2’
> packageVersion('Seurat')
[1] ‘4.3.0’
> sce
class: SingleCellExperiment 
dim: 18975 40 
metadata(0):
assays(2): counts logcounts
rownames(18975): A1BG A1BG-AS1 ... ZYG11A bP-21264C1.2
rowData names(0):
colnames(40): SMC01-T_SMC01.T_CTGTGCTTCAGATAAG
  SMC01-T_SMC01.T_TAGCCGGCACGTCAGC ... SMC01-N_SMC01.N_CCATGTCTCACCTCGT
  SMC01-N_SMC01.N_TCATTACCATCTCCCA
colData names(10): orig.ident nCount_RNA ... sizeFactor label
reducedDimNames(0):
mainExpName: RNA
altExpNames(1): integrated
> spdata
An object of class Seurat 
36122 features across 7347 samples within 2 assays 
Active assay: SCT (18037 features, 3000 variable features)
 1 other assay present: Spatial
 2 dimensional reductions calculated: pca, umap
 1 image present: slice1
> res <- SPOTlight(
    x = sce,
    y = spdata,
    groups = colLabels(sce),
    mgs = mgs_df,
    hvg = hvg,
    weight_id = "mean.AUC",
    group_id = "cluster",
    gene_id = "gene",assay="SCT")
Error in .extract_counts(y, assay, slot) : 
  assay %in% SeuratObject::Assays(x) is not TRUE