filterSeuratObjectByMetadata.Rd
Filter and subset your Seurat object based on metadata column
filterSeuratObjectByMetadata(
object,
samples.to.include,
sample.name,
category.to.filter,
values.to.filter,
keep.or.remove = TRUE,
greater.less.than = "greater than",
seed = 10,
cut.off = 0.5,
legend.position = "top",
reduction = "umap",
plot.as.interactive.plot = FALSE,
legend.symbol.size = 2,
colors = c("aquamarine3", "salmon1", "lightskyblue3", "plum3", "darkolivegreen3",
"goldenrod1", "burlywood2", "gray70", "firebrick2", "steelblue", "palegreen4",
"orchid4", "darkorange1", "yellow", "sienna", "palevioletred1", "gray60", "cyan4",
"darkorange3", "mediumpurple3", "violetred2", "olivedrab", "darkgoldenrod2",
"darkgoldenrod", "gray40", "palegreen3", "thistle3", "khaki1", "deeppink2",
"chocolate3", "paleturquoise3", "wheat1", "lightsteelblue", "salmon", "sandybrown",
"darkolivegreen2", "thistle2",
"gray85", "orchid3", "darkseagreen1",
"lightgoldenrod1", "lightskyblue2", "dodgerblue3", "darkseagreen3", "forestgreen",
"lightpink2", "mediumpurple4", "lightpink1", "thistle", "navajowhite",
"lemonchiffon", "bisque2", "mistyrose", "gray95", "lightcyan3", "peachpuff2",
"lightsteelblue2", "lightyellow2", "moccasin", "gray80", "antiquewhite2",
"lightgrey"),
dot.size = 0.1,
number.of.legend.columns = 1,
dot.size.highlighted.cells = 0.5,
use.cite.seq.data = FALSE
)
A dataset containing your SingleR annotated/merged seurat object
Select which samples to include
Sample Name Column
What kind of metadata you want to subset by. This should be one column in your Metadata table
One or more values where you want to filter
TRUE to filter down to selected values, FALSE to filter out selected values. Default is TRUE
Decide if you want to keep cells above or below the threshold. Default is "greater than"
Set seed for colors
The cut-off you want to use for your greater than/less than filter. Default os 0.5
Select "none" if legend takes up too much space in plot. Default is "top"
What kind of clustering visualization you would like to use for summary plot (umap, tsne, pca, protein_tsne, protein_umap, protein_pca). Default is "umap"
TRUE for interactive, FALSE for static
Your legend symbol size. Default is 2
User-selected colors from palette of 62 unique colors from ColorBrewer.
Size of dots on TSNE/UMAP projection plot. Default is 0.1
Default is 1. If legend is too long, provide more legend columns
Dot size for cells in the after-filter plot which have been highlighted. Default is 0.5
TRUE if you would like to plot Antibody clusters from CITEseq instead of scRNA.
a subset Seurat object
This is a downstream template that should be loaded after Step 5 of the pipeline (SingleR Annotations on Seurat Object)