CONICS icon indicating copy to clipboard operation
CONICS copied to clipboard

Issue Running CONICSMat Tutorial Due To Deprecated SCRAN Function

Open MayaTalukdar opened this issue 5 years ago • 6 comments

Hello,

I am working through the SmartSeq2 scRNA seq of Oligodendroglioma tutorial for CONICSMat and running into an issue with this part:

vg=detectVarGenes(suva_expr,500) ts=calculateTsne(suva_expr,vg) plotTsneGene(ts,suva_expr,c("MBP","CSF1R","ALDOC","OLIG1"))

It appears that detectVarGenes calls a scran function TrendVar, which is deprecated. SCRAN suggests replacement with fitTrendVar, but this takes in both a matrix of counts and a vector of variances, while TrendVar only takes in the count matrix. How can we generate this vector of variances in order to successfully run fitTrendVar and therefore visualize CNVs on a tSNE?

Thank you!

MayaTalukdar avatar Jun 10 '20 21:06 MayaTalukdar

I have the same issue

UmairSeemab avatar Nov 04 '20 10:11 UmairSeemab

Same problem

nlaillerbms avatar Jan 22 '21 13:01 nlaillerbms

same here

Bakr-Mo avatar Aug 26 '21 07:08 Bakr-Mo

same here

andynkili avatar Sep 16 '21 04:09 andynkili

same problem

jcostea avatar Sep 20 '22 12:09 jcostea

Hi

If anyone's still interested in the solution for this or comes looking for it in the future, they can use the below modified function to detect variable genes.

detectVarGenes_custom = function(mat,ngenes=500,FDR=0.00001){ var.out = scran::modelGeneVar(mat) hvg.out = var.out[which(var.out$FDR <= FDR),] hvg.out = hvg.out[order(hvg.out$bio, decreasing=TRUE),] genes=rownames(hvg.out)[1:ngenes] return(genes) }

Aggarwal-Ayush avatar Jan 31 '24 23:01 Aggarwal-Ayush