BuildNicheAssay: Construct an assay for spatial niche analysis

View source: R/utilities.R

BuildNicheAssayR Documentation

Construct an assay for spatial niche analysis

Description

This function will construct a new assay where each feature is a cell label The values represents the sum of a particular cell label neighboring a given cell.

Usage

BuildNicheAssay(
  object,
  fov,
  group.by,
  assay = "niche",
  neighbors.k = 20,
  niches.k = 4
)

Arguments

object

A Seurat object

fov

FOV object to gather cell positions from

group.by

Cell classifications to count in spatial neighborhood

assay

Name for spatial neighborhoods assay

neighbors.k

Number of neighbors to consider for each cell

niches.k

Number of clusters to return based on the niche assay

Value

Seurat object containing a new assay


Seurat documentation built on Nov. 18, 2023, 1:10 a.m.