liger_reduce_dims: Dimensionality reduction using Liger factorization

View source: R/liger_reduce_dims.R

liger_reduce_dimsR Documentation

Dimensionality reduction using Liger factorization

Description

Dimensionality reduction using Liger factorization

Usage

liger_reduce_dims(
  ligerex,
  k = 30,
  lambda = 5,
  thresh = 1e-04,
  max_iters = 100,
  nrep = 1,
  h_init = NULL,
  w_init = NULL,
  v_init = NULL,
  rand_seed = 1,
  print_obj = FALSE,
  quantiles = 50,
  ref_dataset = NULL,
  min_cells = 2,
  knn_k = 20,
  center = FALSE,
  resolution = 1,
  ...
)

Arguments

ligerex

SingleCellExperiment object preprocessed for Liger

Perform iNMF on scaled datasets:

k

Inner dimension of factorization (number of factors). Set to k=30 as default.

lambda

Regularization parameter. Larger values penalize dataset-specific effects more strongly (ie. alignment should increase as lambda increases). Set to lambda=5.0 as default.

thresh

Convergence threshold. Convergence occurs when |obj0-obj|/(mean(obj0,obj)) < thresh (default 1e-4).

max_iters

Maximum number of block coordinate descent iterations to perform (default 100).

nrep

Number of restarts to perform (iNMF objective function is non-convex, so taking the best objective from multiple successive initializations is recommended). For easier reproducibility, this increments the random seed by 1 for each consecutive restart, so future factorizations of the same dataset can be run with one rep if necessary. (default 1)

h_init

Initial values to use for H matrices. (default NULL)

w_init

Initial values to use for W matrix (default NULL)

v_init

Initial values to use for V matrices (default NULL)

rand_seed

Random seed to allow reproducible results (default 1).

print_obj

Print objective function values after convergence (default FALSE).

Quantile align (normalize) factor loadings:

quantiles

Number of quantiles to use for quantile normalization (default 50).

ref_dataset

Name of dataset to use as a "reference" for normalization. By default, the dataset with the largest number of cells is used.

min_cells

Minimum number of cells to consider a cluster shared across datasets (default 2)

knn_k

Number of nearest neighbors for within-dataset knn graph (default 20).

center

Centers the data when scaling factors (useful for less sparse modalities like methylation data). (default FALSE)

resolution

Controls the number of communities detected. Higher resolution -> more communities. (default 1)

...

Additional arguments.

Value

liger object with H, H.norm, W, and V slots sets.

See Also

Other Data integration: integrate_sce(), liger_preprocess(), report_integrated_sce()


combiz/scFlow documentation built on Feb. 25, 2024, 10:25 a.m.