argument_dummy: Argument dummy

View source: R/documentation-dummies.R

argument_dummyR Documentation

Argument dummy

Description

Argument dummy

Usage

argument_dummy()

Arguments

across

Character value or NULL. Specifies the grouping variable of interest.

Use getGroupingOptions() to obtain all variable names that group the barcode spots of your object in a certain manner.

across_subset

Character vector or NULL. Specifies the particular groups of interest the grouping variable specified in argument across contains.

If set to NULL all of them are chosen. You can prefix groups you are NOT interested in with a '-'. (Saves writing if there are more groups you are interested in than groups you are not interested in.)

Use getGroupNames() to obtain all valid input options.

angle_span

Numeric vector of length two. Defines the range of angle values an observation might have when related to the center of the spatial annotation, to be included.

assay_name

Only relevant if the SPATA2 object contains more than one assay: Denotes the assay of interest and thus the molecular modality to use. Defaults to the active assay as set by activateAssay().

bcsp_rm

Character vector or NULL. If character, specifies barcode-spots that are removed before analysis or plotting. (Deprecated in favor of bcs_rm).

bcs_rm

Character vector or NULL. If character, specifies the observations to be removed prior to analysis or visualization by their barcode.

by_section

Logical value. If TRUE, the outline is used which acknowledges the potential for multiple tissue sections. If FALSE, the outline is used which simply outlines everything with one single polygon.

clrp

Character value. Specifies the color palette to be used to represent groups of discrete variables. Run validColorPalettes() to obtain valid input options.

clrp_adjust

Named character vector or NULL. If character, it adjusts the color palette that is used to represent the groups. Names of the input vector must refer to the group and the respective named element denotes the color with which to represent the group.

clrsp

Character value. Specifies the color spectrum to be used to represent continuous values of numeric variables. Run validColorSpectra() to obtain valid input options.

color_by

Character value. The variables by which to color the data points.

concavity

Numeric value. Given to argument concavity of concaveman::concaveman(). Determines the relative measure of concavity. 1 results in a relatively detailed shape, Infinity results in a convex hull. You can use values lower than 1, but they can produce pretty crazy shapes.

dir

Character value. The chosen directory. See details for possible requirements.

discrete_feature

Character value. Specifies the name of the grouping variable of interest. Use getGroupingOptions() to obtain all valid input options.

display_facets

Logical value. If set to TRUE the plot is split via ggplot2::facet_wrap() such that each variable gets it's own subplot.

display_points

Logical value. If set to TRUE points are used additionally to display the results.

display_ribbon

Logical value. If TRUE, a ribbon is displayed around the main line of the plot visualizing uncertainty using standard deviation.

display_title

Logical value. If set to TRUE an informative title is displayed.

eps

Distance measure. Given to eps of dbscan::dbscan(). Determines the size (radius) of the epsilon neighborhood.

error

Logical. If TRUE and the input is invalid the function throws an error.

expand_x, expand_y

Given to argument expand of ggplot2:scale_x/y_continuous().

expand

Specifies image expansion. An image that is cropped based on an image annotation centers around the image annotation. If expand = 0, the default, the dimensions of the image, that is width/x-axis and height/y-axis, are set to include only the image annotation area and nothing more. Using expand, the cropped image section can be adjusted. See section Expansion of cropped image sections for more information.

expand_outline

Distance measure by which the outline of the area is expanded.

format

Character value. Either 'long' or 'wide'. Defaults to 'wide'. If 'wide' each variable gets a column. If 'long', the data.frame is organized such that a column called variables contains the variable names and a column called 'values' contains the values.

ggpLayers

List of ggproto-objects that are added to each plot. Skim ggpLayer*()-functions for more options.

grouping

Character value. The grouping variable of interest. Use getGroupingOptions() to obtain all valid input options.

grouping_variable

Character value. The grouping variable of interest. Use getGroupingOptions() to obtain all valid input options.

h

Numeric value or vector or NULL (see details for more). Denotes the height at which the dendrogom is cut.

hline_alpha, hline_color, hline_size, hline_type

Parameters given to ggplot2::geom_hline() that control the appearance of vertical lines of the plot.

img_alpha

Numeric value. Sets the transparency for the image.

img_name

Character value. The name of the image of interest. If NULL, the active image is chosen by default. Either way, must be one of getImageNames().

img_names

Character vector. The names of the images of interest.

incl_edge

Logical value. If TRUE, the function includes the tissue edge (see identifyTissueOutline()) in the visualization and removes the parts of the outline that transgress the tissues edge.

incr_vert

Logical value. If TRUE, the number of vertices of the polygon to be plotted is increased by linear interpolation. This can lead to smoother visualization but also to increased runtime.

inner

Logical value. Only applies if an image annotation contains a secondary image annotation within its own area. If FALSE, the inner borders of the image annotation are not included in the output.

k

Numeric value or vector or NULL (see details for more). Denotes the number of clusters in which the hierarchical tree is supposed to be split.

method_de

Character value. Denotes the method to according to which the de-analysis is performed. Given to argument test.use of the Seurat::FindAllMarkers()-function. Run SPATA::dea_methods to obtain all valid input options.

method_gs

Character value. The method according to which gene sets will be handled specified as a character of length one. This can be either 'mean or one of 'gsva', 'ssgsea', 'zscore', or 'plage'. The latter four will be given to gsva::GSVA().

method_padj

Character value. The method with which adjusted p-values are calculated. Use validPadjMethods() to obtain all valid input options.

minPts

Numeric value. Given to dbscan::dbscan(). Determines the number of minimum points required in the eps neighborhood for core points (including the point itself)

modality

Character value. The molecular modality of interst.

mtr_name

Character value. The name of the matrix of interest. Defaults to the active matrix of the assay, as denoted by activateMatrix().

n_bins_angle

Numeric value. The number of bins in which observations are categorized in the variable bins_angle.

n_bcsp

Numeric value. Specifies the sample size of barcode-spots and can be set to prevent overplotting.

n_bins

Numeric value. Specifies the exact number of bins the barcodes are binned into.

n_gsets

Numeric value. Maximal number of gene sets whose results are included. The first n_gsets are included starting with the one with the lowest significance value.

normalize

Logical. If set to TRUE values will be scaled to 0-1.

Hint: Variables that are uniformly expressed can not be scaled and are discarded.

n_pcs

Numeric value or NULL. If numeric, specifies the number of principal components to use. If NULL, all principal components are used (as computed with runPCA()).

nrow, ncol

Numeric values or NULL. Used to arrange multiple plots.

line_alpha

Numeric. Affects alpha of main lines of the plot.

line_color

Character. Affects color of the main lines of the plot.

line_size

Numeric. Affects size of the main lines of the plot.

line_type

Character. The line type. One of 'blank', 'solid', 'dashed', 'dotted', 'dotdash', 'longdash' and 'twodash'.

linesize

Numeric value. The size of the line(s) plotted.

object

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

order

Logical value. If TRUE, data points are ordered according to their values before beeing plotted.

order_by

Character value or NULL. If character, the specified variable is used to order the data points.

order_desc

Logical value. If TRUE, reverses the arrangement specified via order_by and/or order.

outer

Logical value. Only applies if an image annotation contains a secondary image annotation within its own area. If FALSE, the outer border of the image annotation is not included in the output.

overwrite

Logical value. Must be TRUE to allow overwriting.

pt_alpha

Numeric value. Specifies the degree of transparency of all points.

pt_clr

Character value. Specifies the color of all points.

pt_clrp

The color palette to be used if the specified variable displayed by color is categorical/discrete. Run validColorPalettes() to see valid input.

pt_clrsp

The color spectrum to be used if the specified variable displayed by color is continuous. Run validColorSpectra() to see valid input.

pt_size

Numeric value. Specifies the size of all points.

rect_alpha

The alpha transparency level of the rectangle's border

rect_color

The color of the rectangle's border.

rect_linesize

The size of the line used for the rectangle's border.

rect_linetype

The type of line used for the rectangle's border.

relevel

Logical value. If set to TRUE the input order of across_subset determines the order in which the groups of interest are displayed. Groups that are not included are dropped which affects the colors with which they are displayed.

resolution

Distance measure. The resolution with which the expression gradient is inferred. Defaults are platform specific. See more in detail section of recSgsRes().

sc_input

Data.frame that contains the results from single cell deconvolution. Must have at least three columns:

  • x : numeric. Position of cell on the x axis in pixel.,

  • y : numeric. Position of cell on the y axis in pixel.,

  • cell_type : factor Cell type of the cell.

scales, ncol, nrow

Affects the way the subplots are displayed.

sctm_interpolate, sctm_pixels

Given to the corresponding arguments of scattermore::geom_scattermore(). Note: With increasing sctm_pixels the point size must be adjusted with the argument pt_size.

sgmt_alpha, sgmt_color, sgmt_size, sgmt_type

Parameters given to ggplot2::geom_segment() that control the appearance of segments of the plot.

section_subset

Character vector or NULL. If character, specifies the tissue sections of interest and filters the output accordingly.

signif_var

Character value. Determines what to be considered while checking for significance. Either 'pval' (p-Value) or 'fdr' (False Discovery Rate).

signif_threshold

Numeric value. Significance values below signif_threshold are not included.

simplify

Logical. If set to TRUE the output list is simplified to a vector if possible. If set to FALSE a list is returned.

smooth

Logical. If TRUE, a loess fit is used to smooth the values.

smooth_span

Numeric value. Controls the degree of smoothing. Given to argument span of stats::loess().

square

Logical value. Most image annotations come in variable shapes and have different horizontal and vertical diameters. Therefore, height and width of the image section are usually not equal. If square = TRUE, the cropped section of the image that contains the annotated structure is forced into a square: the bigger diameter of both is taken as default. E.g. if the horizontal diameter of the image annotation is 1mm and the vertical diameter is 1.5mm, the output image will have height and width of 1.5mm. That is, in terms of coordinates, an x-range and a y-range of 1.5mm.

Processing of the image output depending on argument expand happens afterwards.

summarize_with

Character value. Name of the function with which to summarize.

spatial_method

Character value. The name of the spatial method that underlies the experiment. Must be one of validSpatialMethods(). Defaults to 'Unknown'.

tags

Character vector or NULL. If character, the tags for the image annotation selection. See section Selection of spatial annotations for more information.

test

Character value. One of c('any'. 'all', 'identical', 'not_identical', 'none'). Specifies how input for tags is used to select spatial annotations. See section Selection of spatial annotations for more information.

text_alpha, text_color, text_nudge_x, text_nudge_y, text_size, text_type

Parameters given to ggplot2::geom_text() that control the appearance of text of the plot.

transform

Logical value. Ignored if no images exist in the object. If TRUE, spatial transformation instructions saved during image alignment of the image img_name are applied. Only relevant if there are any images registered in the SPATA2 object.

transform_with

List or NULL. If list, can be used to transform continuous variables before usage. Names of the list slots refer to the variable. The content of the slot refers to the transforming functions. E.g if the variable of interest is GFAP gene expression, the following would work:

  • Single function: transform_with = log10,

  • Multiple functions: ⁠transform_with = list(GFAP = list(log10, log2)⁠

In case of plotting: Useful if you want to apply more than one transformation on variables mapped to plotting aesthetics. Input for transform_with is applied before the respective <aes>_trans argument.

unit

Character value. Specifies the desired unit in which distance measures or area measures are provided. Run validUnitsOfLength() or validUnitsOfArea() for valid input options.

use_scattermore

Logical value. If TRUE, data points are plotted with scattermore::geom_scattermore() which allows quick plotting of several thousand data points. If the number of data points plotted is bigger than 10.000 it is used anyway.

variables

Character vector. The names of the data variables of interest.

verbose

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

(Warning messages will always be printed.)

vline_alpha, vline_color, vline_size, vline_type

Parameters given to ggplot2::geom_vline() that control the appearance of vertical lines of the plot.

whole_sample

Logical. If TRUE, normalization of the values used takes place in the light of the complete sample.

x_nth

Numeric value. If the number of breaks/labels on the x-axis becomes too high x_nth can be used to reduce it. If x_nth is 1, every label is kept. If 2, every second label is kept. If 3, every third label is kept. And so on.

xrange, yrange

Distance vector of length two or NULL. If not NULL, specifies the x- and y-range to which the spatial output is cropped. E.g. xrange = c(200, 500) results in the two dimensional space being cropped from x-coordinate 200px up to x-coordinate 500px. If NULL, the original range is used.

...

Used to absorb deprecated arguments or functions.


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