welch-lab / liger

R package for integrating and analyzing multiple single-cell datasets
GNU General Public License v3.0
389 stars 78 forks source link

issue in integrade seurat object by liger #169

Closed EDGtentacles closed 4 years ago

EDGtentacles commented 4 years ago

Thanks for your great work and recent update of seurat-wrappers. I followed the vignette of liger to test the new function RunQuantileNorm

 library(liger)
 library(Seurat)
 library(SeuratData)
 library(SeuratWrappers)
 InstallData("pbmcsca")
 data("pbmcsca")
 pbmcsca <- NormalizeData(pbmcsca)
 pbmcsca <- FindVariableFeatures(pbmcsca)
 pbmcsca <- ScaleData(pbmcsca, split.by = "Method", do.center = FALSE)
 pbmcsca <- RunOptimizeALS(pbmcsca, k = 20, lambda = 5, split.by = "Method")

When I go to next step, the new fuction has issue:

 > pbmcsca <- RunQuantileNorm(pbmcsca, split.by = "Method")
 Error in ncol(object@H[[1]]) : 
   trying to get slot "H" from an object of a basic class ("list") with no slots

I test the data ifnb in vignette and my own data. It turns out to be the same error.

Here is sessionInfo() output:

 R version 4.0.0 (2020-04-24)
 Platform: x86_64-w64-mingw32/x64 (64-bit)
 Running under: Windows 10 x64 (build 14393)

 Matrix products: default

 locale:
 [1] LC_COLLATE=Chinese (Simplified)_China.936  LC_CTYPE=Chinese (Simplified)_China.936    LC_MONETARY=Chinese (Simplified)_China.936
 [4] LC_NUMERIC=C                               LC_TIME=Chinese (Simplified)_China.936    

 attached base packages:
 [1] stats4    parallel  stats     graphics  grDevices utils     datasets  methods   base     

 other attached packages:
  [1] ifnb.SeuratData_3.1.0       SeuratWrappers_0.1.0        pbmcsca.SeuratData_3.0.0    SeuratData_0.2.1           
  [5] Seurat_3.1.5                liger_0.5.0.9000            patchwork_1.0.0             Matrix_1.2-18              
  [9] cowplot_1.0.0               monocle3_0.2.1              SingleCellExperiment_1.10.1 SummarizedExperiment_1.18.1
 [13] DelayedArray_0.14.0         matrixStats_0.56.0          GenomicRanges_1.40.0        GenomeInfoDb_1.24.0        
 [17] IRanges_2.22.2              S4Vectors_0.26.1            Biobase_2.48.0              BiocGenerics_0.34.0        
skpalan commented 4 years ago

Hi, thanks for your comment. Please update liger to version 0.5.0 (you are using 0.5.0.9000 which is a pre-release version). This should solve the problem.