Visualize cells according to spatial AND dimension reduction coordinates in ggplot mode
spatDimGenePlot2D(
gobject,
show_image = F,
gimage = NULL,
image_name = "image",
expression_values = c("normalized", "scaled", "custom"),
plot_alignment = c("vertical", "horizontal"),
genes,
dim_reduction_to_use = "umap",
dim_reduction_name = "umap",
dim1_to_use = 1,
dim2_to_use = 2,
dim_point_shape = c("border", "no_border"),
dim_point_size = 1,
dim_point_alpha = 1,
dim_point_border_col = "black",
dim_point_border_stroke = 0.1,
show_NN_network = F,
show_spatial_network = F,
dim_network_color = "gray",
nn_network_to_use = "sNN",
network_name = "sNN.pca",
dim_edge_alpha = NULL,
scale_alpha_with_expression = FALSE,
sdimx = "sdimx",
sdimy = "sdimy",
spatial_network_name = "Delaunay_network",
spatial_network_color = NULL,
show_spatial_grid = F,
grid_color = NULL,
spatial_grid_name = "spatial_grid",
spat_point_shape = c("border", "no_border", "voronoi"),
spat_point_size = 1,
spat_point_alpha = 1,
spat_point_border_col = "black",
spat_point_border_stroke = 0.1,
spat_edge_alpha = NULL,
cell_color_gradient = c("blue", "white", "red"),
gradient_midpoint = NULL,
gradient_limits = NULL,
cow_n_col = 2,
cow_rel_h = 1,
cow_rel_w = 1,
cow_align = "h",
show_legend = T,
legend_text = 8,
dim_background_color = "white",
spat_background_color = "white",
vor_border_color = "white",
vor_max_radius = 200,
vor_alpha = 1,
axis_text = 8,
axis_title = 8,
show_plot = NA,
return_plot = NA,
save_plot = NA,
save_param = list(),
default_save_name = "spatDimGenePlot2D"
)
giotto object
show a tissue background image
a giotto image
name of a giotto image
gene expression values to use
direction to align plot
genes to show
dimension reduction to use
dimension reduction name
dimension to use on x-axis
dimension to use on y-axis
dim reduction points with border or not (border or no_border)
dim reduction plot: point size
transparancy of dim. reduction points
color of border around points
stroke size of border around points
show underlying NN network
show underlying spatial netwok
color of NN network
type of NN network to use (kNN vs sNN)
name of NN network to use, if show_NN_network = TRUE
dim reduction plot: column to use for alpha of the edges
scale expression with ggplot alpha parameter
spatial x-axis dimension name (default = 'sdimx')
spatial y-axis dimension name (default = 'sdimy')
name of spatial network to use
color of spatial network
show spatial grid
color of spatial grid
name of spatial grid to use
spatial points with border or not (border or no_border)
spatial plot: point size
transparancy of spatial points
color of border around points
stroke size of border around points
edge alpha
vector with 3 colors for numeric data
midpoint for color gradient
vector with lower and upper limits
cowplot param: how many columns
cowplot param: relative height
cowplot param: relative width
cowplot param: how to align
show legend
size of legend text
color of plot background for dimension plot
color of plot background for spatial plot
border colorr for voronoi plot
maximum radius for voronoi 'cells'
transparancy of voronoi 'cells'
size of axis text
size of axis title
show plots
return ggplot object
directly save the plot [boolean]
list of saving parameters, see showSaveParameters
default save name for saving, don't change, change save_name in save_param
ggplot
Description of parameters.
Other spatial and dimension reduction gene expression visualizations:
spatDimGenePlot3D()
,
spatDimGenePlot()
data(mini_giotto_single_cell)
all_genes = slot(mini_giotto_single_cell, 'gene_ID')
selected_genes = all_genes[1]
spatDimGenePlot2D(mini_giotto_single_cell, genes = selected_genes,
dim_point_size = 3, spat_point_size = 3,
cow_n_col = 1, plot_alignment = 'horizontal')