Seurat: Extend ScoreJackStraw dim limit above 20

Created on 10 Jul 2019  路  3Comments  路  Source: satijalab/seurat

Hi,

ScoreJackStraw dim above 20 will give a Error in pAll[, dims, drop = FALSE] : subscript out of bounds.

A lot time as in the case of Mouse Altas 250K, we'd have to use PCA beyond 20, and we would very much like to see a JackStraw plot. Are there any ways to do this in a version 3 ?

Most helpful comment

Hi,

If you want to extend, for example, to 50 on the pbmc3k dataset from the tutorial, you could do so as follows:

pbmc3k <- JackStraw(pbmc3k, dims = 50)
pbmc3k <- ScoreJackStraw(pbmc3k, dims = 1:50)
JackStrawPlot(pbmc3k, dims = 1:50)

All 3 comments

I am not from Seurat team, but I think you will need increase the value of "num.pc" in JackStraw function before running ScoreJackStraw to the required number in your case. By default JackStraw uses 20.

@asmariyaz23

Thanks for a pointer, though I did not see a "num.pc" argument in JackStarw function ;

JackStraw(object, reduction = "pca", assay = NULL, dims = 20, num.replicate = 100, prop.freq = 0.01, verbose = TRUE, maxit = 1000)

I tried increasing "dims" to 50 and set "dim=1:50" in JackStrawPlot gave the same error, Max dimension is 20

I do appreciate any further inputs.

Hi,

If you want to extend, for example, to 50 on the pbmc3k dataset from the tutorial, you could do so as follows:

pbmc3k <- JackStraw(pbmc3k, dims = 50)
pbmc3k <- ScoreJackStraw(pbmc3k, dims = 1:50)
JackStrawPlot(pbmc3k, dims = 1:50)
Was this page helpful?
0 / 5 - 0 ratings

Related issues

farhanma picture farhanma  路  3Comments

htc502 picture htc502  路  3Comments

kysbbubbu picture kysbbubbu  路  3Comments

whitleyo picture whitleyo  路  3Comments

igordot picture igordot  路  3Comments