Visualize the evaluation of the fit of a numeric variable against models around the area of an image annotation.

plotClockplot(object, ...)

# S4 method for spata2
plotClockplot(
  object,
  id,
  variables,
  distance = NA_integer_,
  n_bins_circle = NA_integer_,
  binwidth = getCCD(object),
  angle_span = c(0, 360),
  n_angle_bins = 12,
  summarize_with = "mean",
  model_subset = NULL,
  model_remove = NULL,
  model_add = NULL,
  layout = 1,
  switch = NULL,
  fill = "steelblue",
  ...
)

# S4 method for ImageAnnotationScreening
plotClockplot(
  object,
  variables,
  model_subset = NULL,
  model_remove = NULL,
  layout = 1,
  switch = NULL,
  fill = "steelblue",
  ...
)

Arguments

object

Any object for which a method has been defined.

...

Used to absorb deprecated arguments or functions.

id

Character value. The ID of the image annotation of interest.

variables

Character vector. The numeric variables of interest. Must be inside:

  • Gene sets Must be in getGeneSets()

  • Genes Must be in getGenes()

  • Features Must be in getFeatureNames(..., of_class = "numeric")

distance

Distance value. Specifies the distance from the border of the image annotation to the horizon in the periphery up to which the screening is conducted. (See details for more.) - See details of ?is_dist for more information about distance values.

n_bins_circle

Numeric value or vector of length 2. Specifies how many times the area is buffered with the value denoted in binwidth. (See details for more.)

binwidth

Distance value. The width of the circular bins to which the barcode-spots are assigned. We recommend to set it equal to the center-center distance: binwidth = getCCD(object). (See details for more.) - See details of ?is_dist for more information about distance values.

angle_span

Numeric vector of length 2. Confines the area screened by an angle span relative to the center of the image annotation. (See details fore more.)

summarize_with

Character value. Either 'mean' or 'median'. Specifies the function with which the bins are summarized.

model_subset

Character value. Used as a regex to subset models. Use validModelNames() to obtain all model names that are known to SPATA2 and showModels() to visualize them.

model_remove

Character value. Used as a regex to remove models are not supposed to be included.

model_add

Named list. Every slot in the list must be either a formula containing a function that takes a numeric vector as input and returns a numeric vector with the same length as its input vector. Or a numeric vector with the same length as the input vector. Test models with showModels().

switch

By default, the labels are displayed on the top and right of the plot. If "x", the top labels will be displayed to the bottom. If "y", the right-hand side labels will be displayed to the left. Can also be set to "both".

fill

Character value. The color with which the columns are filled.