Skip to contents

This function subsets a SpatialExperiment object based on specified x and y coordinate ranges. It is useful in spatial transcriptomics for isolating specific regions of interest.

Usage

subsetSPE(spe, colRange = NULL, rowRange = NULL)

Arguments

spe

A SpatialExperiment object containing spatial coordinates and associated data.

colRange

A numeric vector of length 2, specifying the minimum and maximum pxl_col_in_fullres.

rowRange

A numeric vector of length 2, specifying the minimum and maximum pxl_row_in_fullres.

Value

A subset of the SpatialExperiment object, including only the data within the specified coordinate ranges.