ReadVizgen {Seurat} | R Documentation |
Read and Load MERFISH Input from Vizgen
Description
Read and load in MERFISH data from Vizgen-formatted files
Usage
ReadVizgen(
data.dir,
transcripts = NULL,
spatial = NULL,
molecules = NULL,
type = "segmentations",
mol.type = "microns",
metadata = NULL,
filter = NA_character_,
z = 3L
)
LoadVizgen(data.dir, fov, assay = "Vizgen", z = 3L)
Arguments
data.dir |
Path to the directory with Vizgen MERFISH files; requires at least one of the following files present:
|
transcripts |
Optional file path for counts matrix; pass |
spatial |
Optional file path for spatial metadata; pass |
molecules |
Optional file path for molecule coordinates file; pass
|
type |
Type of cell spatial coordinate matrices to read; choose one or more of:
|
mol.type |
Type of molecule spatial coordinate matrices to read; choose one or more of:
|
metadata |
Type of available metadata to read; choose zero or more of:
|
filter |
A character to filter molecules by, pass |
z |
Z-index to load; must be between 0 and 6, inclusive |
fov |
Name to store FOV as |
assay |
Name to store expression matrix as |
Value
ReadVizgen
: A list with some combination of the
following values:
-
“
transcripts
”: a sparse matrix with expression data; cells are columns and features are rows -
“
segmentations
”: a data frame with cell polygon outlines in three columns: “x”, “y”, and “cell” -
“
centroids
”: a data frame with cell centroid coordinates in three columns: “x”, “y”, and “cell” -
“
boxes
”: a data frame with cell box outlines in three columns: “x”, “y”, and “cell” -
“
microns
”: a data frame with molecule micron coordinates in three columns: “x”, “y”, and “gene” -
“
pixels
”: a data frame with molecule pixel coordinates in three columns: “x”, “y”, and “gene” -
“
metadata
”: a data frame with the cell-level metadata requested bymetadata
LoadVizgen
: A Seurat
object
Progress Updates with progressr
This function uses
progressr to
render status updates and progress bars. To enable progress updates, wrap
the function call in with_progress
or run
handlers(global = TRUE)
before running
this function. For more details about progressr, please read
vignette("progressr-intro")
Parallelization with future
This function uses
future to enable
parallelization. Parallelization strategies can be set using
plan
. Common plans include “sequential
”
for non-parallelized processing or “multisession
” for parallel
evaluation using multiple R sessions; for other plans, see the
“Implemented evaluation strategies” section of
?future::plan
. For a more thorough introduction
to future, see
vignette("future-1-overview")
Note
This function requires the data.table package to be installed