reduceSpataObject: Reduce SPATA2 object

reduceSpataObjectR Documentation

Reduce SPATA2 object

Description

This function reduces a SPATA2 object to a minimal version by removing analysis progress and other non-essential data.

Usage

reduceSpataObject(object)

Arguments

object

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

Details

The following components are removed or reduced:

  • @assays: The @analysis and @mtr_proc slots are cleared, and @meta_var is reduced to only include molecule names.

  • @data_add: Cleared completely.

  • @dim_red: Cleared completely.

  • @meta: Only the barcodes column is retained in the metadata.

  • @spatial:

    • @annotations: Cleared completely.

    • @images: The @outline and @pixel_content slots are cleared.

    • @trajectories: Cleared completely.

    • @outline: Cleared completely.

    Furthermore, all images are unload with unlaodImages().

Value

The updated input object, containing the added, removed or computed results.

Examples


# Assuming 'object' is a valid SPATA2 object
reduced_object <- reduceSpataObject(object)


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