Prepare parameters setup for SpatialAnno model fitting.

model_set_SpatialAnno(
  error_heter = TRUE,
  wpca_int = TRUE,
  int.model = "SCINA",
  beta_grid = seq(0.1, 2.5, by = 0.2),
  maxIter_ICM = 6,
  maxIter = 30,
  epsLogLik = 1e-05,
  Sigma_diag = FALSE,
  add_Unknown = TRUE,
  verbose = TRUE,
  seed = 1
)

Arguments

error_heter

a logical value, whether use the heterogenous error for SpatialAnno model, default as TRUE. If error.heter=FALSE, then the homogenuous error is used for probabilistic PCA model in DR-SC.

wpca_int

an optional logical value, means whether use the weighted PCA to obtain the initial values of loadings and other paramters, default as FALSE which means the ordinary PCA is used.

int.model

an optional string, specify model for computing the initial values for SpatialAnno (one of "SCINA" and "scSorter"), default as "SCINA".

beta_grid

a numeric vector, specify the smoothness parameter of Random Markov Field. The default is seq(0.2,4,0.2).

maxIter_ICM

the maximum iteration of ICM step, default as 6.

maxIter

the maximum iteration of ICM-EM algorithm. The default is 25

epsLogLik

an optional positive vlaue, tolerance vlaue of relative variation rate of the observed pseudo log-loglikelihood value, defualt as '1e-5'.

add_Unknown

a logical value, whether allow "Unknown" in the identified cell types, default as TRUE.

verbose

a logical value, whether output the information in iteration.

seed

a postive integer, the random seed to be set.

approxPCA

an optional logical value, whether use approximated PCA to speed up the computation for initial values.

Examples

model_set_SpatialAnno(int.model='scSorter')
#> $error_heter
#> [1] TRUE
#> 
#> $add_Unknown
#> [1] TRUE
#> 
#> $beta_grid
#>  [1] 0.1 0.3 0.5 0.7 0.9 1.1 1.3 1.5 1.7 1.9 2.1 2.3 2.5
#> 
#> $maxIter_ICM
#> [1] 6
#> 
#> $maxIter
#> [1] 30
#> 
#> $epsLogLik
#> [1] 1e-05
#> 
#> $wpca_int
#> [1] TRUE
#> 
#> $int.model
#> [1] "scSorter"
#> 
#> $Sigma_diag
#> [1] FALSE
#> 
#> $seed
#> [1] 1
#> 
#> $verbose
#> [1] TRUE
#>