monocle-release icon indicating copy to clipboard operation
monocle-release copied to clipboard

New Error in Generate CDS

Open cohenp05 opened this issue 6 years ago • 6 comments

Hello,

I am trying to make a CDS object by pulling data from a Seurat object that I have already scaled, regressed out cell cycle data, and dimensionally reduced. I have read the other posts addressing this, but with Seurat v3 it seems that importCDS will not accept the new Seurat objects. To get around this I had been generating the CDS object by pulling each piece of data from the Seurat object individually. I'm not sure what I'm doing wrong because I was generating a working object before, but now I'm getting an error "@deviance() not finishedneeds checking, but I'm sure it worksError in get(fun.name) : object 'natural.ig' not found" Please help!

Here is my code for generating the CDS `Monocyte_exp <- GetAssayData(Monocytes_RNA, slot = "scale.data") pd <- [email protected] fd <- rownames(Monocytes_RNA) fd <- as.data.frame(fd) rownames(fd) <- fd[,1] colnames(fd) <- c("gene_short_name")

pd <- new("AnnotatedDataFrame", data = pd) fd <- new("AnnotatedDataFrame", data = fd) Monocyte_Monocle <- newCellDataSet(as.matrix(Monocyte_exp), phenoData = pd, featureData = fd, expressionFamily = inverse.gaussianff() )`

cohenp05 avatar Jan 02 '19 23:01 cohenp05

I am encountering the same issue, again trying to make a CDS object from data scaled etc. with Seurat v3 and running Monocle v2.6.4. Additionally, I get the following error, despite taking my featureData from the rownames of the dataset and renaming the appropriate column as "gene_short_name" (as above): Error in validObject(.Object) : invalid class “CellDataSet” object: featureNames differ between assayData and featureData

Thanks in advance!

vmoignard avatar Jan 15 '19 08:01 vmoignard

I am also having this issue.

Thanks!

tmccra2 avatar Jan 18 '19 22:01 tmccra2

Hello,

I seem to be getting exactly the same error. Can you please share how you managed to solve this?

Thank you!

shikhagupta68 avatar Jun 17 '19 10:06 shikhagupta68

Just make sure that identical(rownames(fd),rownames(matrix)) is true. Order alphabetically and make sure they are the same length.

Pestudkaru avatar Feb 26 '20 13:02 Pestudkaru

I met with the same error. And I found the reason for the error is that the colnames(matrix) vs rownames(pd) not in the same order. You can just add one line of code Monocyte_exp <- Monocyte_exp[, rownames(pd)] before newCellDataSet to set the order.

myshu2017-03-14 avatar May 25 '21 07:05 myshu2017-03-14

I met with the same error. And I found the reason for the error is that the colnames(matrix) vs rownames(pd) not in the same order. You can just add one line of code Monocyte_exp <- Monocyte_exp[, rownames(pd)] before newCellDataSet to set the order.

Thanks a lot!

liuyu988 avatar Dec 16 '21 08:12 liuyu988