identify significant prinicipal components (PCs)
jackstrawPlot(
gobject,
spat_unit = NULL,
feat_type = NULL,
expression_values = c("normalized", "scaled", "custom"),
reduction = c("cells", "feats"),
feats_to_use = NULL,
center = FALSE,
scale_unit = FALSE,
ncp = 20,
ylim = c(0, 1),
iter = 10,
threshold = 0.01,
verbose = TRUE,
show_plot = NULL,
return_plot = NULL,
save_plot = NULL,
save_param = list(),
default_save_name = "jackstrawPlot"
)
giotto object
spatial unit (e.g. "cell")
feature type (e.g. "rna", "dna", "protein")
expression values to use
cells or genes
subset of features to use for PCA
center data before PCA
scale features before PCA
number of principal components to calculate
y-axis limits on jackstraw plot
number of interations for jackstraw
p-value threshold to call a PC significant
show progress of jackstraw method
logical. show plot
logical. return ggplot object
logical. save the plot
list of saving parameters, see showSaveParameters
default save name for saving, don't change, change save_name in save_param
ggplot object for jackstraw method
The Jackstraw method uses the permutationPA
function. By systematically permuting genes it identifies robust, and thus
significant, PCs.
g <- GiottoData::loadGiottoMini("visium")
#> 1. read Giotto object
#> 2. read Giotto feature information
#> 3. read Giotto spatial information
#> 3.1 read Giotto spatial shape information
#> 3.2 read Giotto spatial centroid information
#> 3.3 read Giotto spatial overlap information
#> 4. read Giotto image information
#>
#> checking default envname 'giotto_env'
#> a system default python environment was found
#> Using python path:
#> "/usr/bin/python3"
jackstrawPlot(gobject = g)
#> Error: package 'jackstraw' is not yet installed
#>
#> To install:
#> install.packages(c("jackstraw"))