R/Plotting_Seurat_Iterative.R
Iterate_Plot_Density_Custom.Rd
Create and save plots for gene list with single command. Requires Nebulosa package from Bioconductor.
Iterate_Plot_Density_Custom(
seurat_object,
gene_list,
viridis_palette = "magma",
custom_palette = NULL,
pt.size = 1,
file_path = NULL,
file_name = NULL,
file_type = NULL,
single_pdf = FALSE,
output_width = NULL,
output_height = NULL,
dpi = 600,
reduction = NULL,
combine = TRUE,
joint = FALSE,
...
)
Seurat object name.
vector of genes to plot. If a named vector is provided then the names for each gene
will be incorporated into plot title if single_pdf = TRUE
or into file name if FALSE
.
color scheme to use.
color for non-expressed cells.
Adjust point size for plotting.
directory file path and/or file name prefix. Defaults to current wd.
name suffix and file extension.
File type to save output as. Must be one of following: ".pdf", ".png", ".tiff", ".jpeg", or ".svg".
saves all plots to single PDF file (default = FALSE). `file_type`` must be .pdf.
the width (in inches) for output page size. Default is NULL.
the height (in inches) for output page size. Default is NULL.
dpi for image saving.
Dimensionality Reduction to use (if NULL then defaults to Object default)
Create a single plot? If FALSE, a list with ggplot objects is returned.
NULL. This function only supports joint = FALSE
. Leave as NULL to generate plots. To iterate joint plots see function: Iterate_Plot_Density_Joint
.
Extra parameters passed to plot_density
.
Saved plots
if (FALSE) {
Iterate_Plot_Density_Custom(seurat_object = object, gene_list = DEG_list, viridis_palette = "magma",
file_path = "plots/", file_name = "_density_plots", file_type = ".jpg", dpi = 600)
}