addSegmentationVariable: Add Segmentation Variable

addSegmentationVariableR Documentation

Add Segmentation Variable

Description

This function adds a new, empty segmentation variable to the metadata of the given object for further naming within createSpatialSegmentation().

Usage

addSegmentationVariable(
  object,
  name,
  init_value = "unnamed",
  verbose = NULL,
  ...
)

Arguments

object

An object of class SPATA2 or, in case of S4 generics, objects of classes for which a method has been defined.

name

A character string specifying the name of the segmentation variable to add.

init_value

A character string specifying the initial value of each observation. Defaults to unnnamed.

verbose

Logical. If TRUE, informative messages regarding the computational progress will be printed.

(Warning messages will always be printed.)

...

Used to absorb deprecated arguments or functions.

Details

This function checks if the provided segmentation variable name is not already used by a different meta feature, molecule or molecular signature in the object. If the name is unique, it adds the segmentation variable to the object's metadata.

See Also

getSegmVarNames(), getFeatureNames(), getMetaDf(), setMetaDf()


theMILOlab/SPATA2 documentation built on Feb. 8, 2025, 11:41 p.m.