SeuratMap2Ref

Map the seurat object to reference

See: https://satijalab.org/seurat/articles/integration_mapping.html and https://satijalab.org/seurat/articles/multimodal_reference_mapping.html

Environment Variables

  • ncores (type=int;order=-100): Default: 1.
    Number of cores to use.
    When split_by is used, this will be the number of cores for each object to map to the reference.
    When split_by is not used, this is used in future::plan(strategy = "multicore", workers = <ncores>) to parallelize some Seurat procedures.
    See also: https://satijalab.org/seurat/archive/v3.0/future_vignette.html
  • mutaters (type=json): Default: {}.
    The mutaters to mutate the metadata.
    This is helpful when we want to create new columns for split_by.
  • use: A column name of metadata from the reference (e.g. celltype.l1, celltype.l2) to transfer to the query as the cell types (ident) for downstream analysis. This field is required.
    If you want to transfer multiple columns, you can use envs.MapQuery.refdata.
  • ident: Default: seurat_clusters.
    The name of the ident for query transferred from envs.use of the reference.
  • ref: The reference seurat object file.
    Either an RDS file or a h5seurat file that can be loaded by Seurat::LoadH5Seurat().
    The file type is determined by the extension. .rds or .RDS for RDS file, .h5seurat or .h5 for h5seurat file.
  • refnorm (choice): Default: auto.
    Normalization method the reference used. The same method will be used for the query.
    • NormalizeData: Using NormalizeData.
    • SCTransform: Using SCTransform.
    • auto: Automatically detect the normalization method.
      If the default assay of reference is SCT, then SCTransform will be used.
  • split_by: The column name in metadata to split the query into multiple objects.
    This helps when the original query is too large to process.
  • skip_if_normalized: Default: True.
    Skip normalization if the query is already normalized.
    Since the object is supposed to be generated by SeuratPreparing, it is already normalized.
    However, a different normalization method may be used.
    If the reference is normalized by the same method as the query, the normalization can be skipped.
    Otherwise, the normalization cannot be skipped.
    The normalization method used for the query set is determined by the default assay.
    If SCT, then SCTransform is used; otherwise, NormalizeData is used.
    You can set this to False to force re-normalization (with or without the arguments previously used).
  • SCTransform (ns): Arguments for SCTransform()
    • do-correct-umi (flag): Default: False.
      Place corrected UMI matrix in assay counts layer?
    • do-scale (flag): Default: False.
      Whether to scale residuals to have unit variance?
    • do-center (flag): Default: True.
      Whether to center residuals to have mean zero?
    • <more>: See https://satijalab.org/seurat/reference/sctransform.
      Note that the hyphen (-) will be transformed into . for the keys.
  • NormalizeData (ns): Arguments for NormalizeData()
  • FindTransferAnchors (ns): Arguments for FindTransferAnchors()
    • normalization-method (choice): Name of normalization method used.
      • LogNormalize: Log-normalize the data matrix
      • SCT: Scale data using the SCTransform method
      • auto: Automatically detect the normalization method.
        See envs.refnorm.
    • reference-reduction: Default: spca.
      Name of dimensional reduction to use from the reference if running the pcaproject workflow.
      Optionally enables reuse of precomputed reference dimensional reduction.
    • <more>: See https://satijalab.org/seurat/reference/findtransferanchors.
      Note that the hyphen (-) will be transformed into . for the keys.
  • MapQuery (ns): Arguments for MapQuery()
    • reference-reduction: Default: spca.
      Name of reduction to use from the reference for neighbor finding
    • reduction-model: Default: wnn.umap.
      DimReduc object that contains the umap model.
    • refdata (type=json): Default: {}.
      Extra data to transfer from the reference to the query.
    • <more>: See https://satijalab.org/seurat/reference/mapquery.
      Note that the hyphen (-) will be transformed into . for the keys.
  • MappingScore (ns): Arguments for MappingScore()

Metadata

The metadata of the Seurat object will be updated with the cluster assignments (column name determined by envs.name):

SeuratMap2Ref-metadata