ascend icon indicating copy to clipboard operation
ascend copied to clipboard

runTSNE step couldn't finish

Open lixin4306ren opened this issue 6 years ago • 3 comments

the command I used: scran_normalised <- runTSNE(scran_normalised, PCA = FALSE)

The dataset has ~18000 cells and ~20000 genes, after overnight running, it still couldn't finish.

lixin4306ren avatar Dec 12 '18 01:12 lixin4306ren

Hi @lixin4306ren ,

The TSNE function runs a lot faster if you run it on PCA data instead of the expression data. This reduces the number of dimensions down to the number of genes.

If you wish to use TSNE directly on your expression data, you can extract the normalised counts using the normcounts or logcounts functions for use directly with the Rtsne function from the Rtsne package. You can leverage more cores and use the partial_pca argument with this function, that should hopefully speed up the processing time. You can then store it back into the EMSet using the reducedDim function.

asenabouth avatar Dec 12 '18 02:12 asenabouth

Thank you for your prompt reply! Is there any significant difference between tsne results generated directly from the expression matrix and that based on PCA data? Thanks.

lixin4306ren avatar Dec 12 '18 03:12 lixin4306ren

The results will look different, as that's the nature of TSNE. Here's a comparison of a TSNE generated from PCA-reduced values: pca_tsne_plot

And directly from expression data: exprs_tsne_plot

asenabouth avatar Dec 12 '18 03:12 asenabouth