我正在尝试使用 Monocle(不是 Monocle3)将 Seurat3 对象中的数据集作为轨迹的子集,如下所示:
mono <- subset(Seurat.combined,idents=c(0,2,3,5))
然后使用newCellDataSet构造单片眼镜CDS(mono_cds),调用reduceDimension时出现错误:
mono_cds <- reduceDimension(mono_cds, max_components = 2,
reduction_method = "DDRTree")
DDRTree will be eventually deprecated in reduceDimension call and be used in learnGraph function instead. We are calling learnGraph for you now.
Error in RANN::nn2(data, data, k + 1, searchtype = "standard") :
no points in data!
In addition: Warning message:
In (function (data, pd, k = 20, weight = F, louvain_iter = 1, resolution = NULL, :RANN counts the point itself, k must be smaller than
the total number of points - 1 (all other points) - 1 (itself)!
Timing stopped at: 0.008 0 0.008
问题可能是Seurat对象的子集引起的,如果我不子集数据集并使用整个Seurat3对象构建单片CDS,没有问题。
我正在使用 monocle_2.99.3 和 Seurat 3.1.2。
有什么帮助吗?谢谢!