moveCoords: Move coordinates if they don't match image

View source: R/coordinateGeneration.R

moveCoordsR Documentation

Move coordinates if they don't match image

Description

If generated coordinates do not match the image use this function to move coordinates. Coordinates are only changed 1 pixel at a time.

Usage

moveCoords(overlay, direction = "right")

Arguments

overlay

SpatialOverlay object

direction

which direction should coordinates move: left, right, up, down

Value

SpatialOverlay object

Examples


muBrain <- readRDS(unzip(system.file("extdata", "muBrainSubset_SpatialOverlay.zip", 
                                    package = "SpatialOmicsOverlay")))
head(coords(muBrain), 3)
head(coords(moveCoords(muBrain, direction = "up")), 3)                                    


Nanostring-Biostats/SpatialOmicsOverlay documentation built on April 20, 2024, 5:36 a.m.