Skip to main content

Module convert

Module convert 

Source

Structs§

MatrixLayout
Where a 10x file keeps its sparse matrix and the names of its rows and columns, and which rows to keep: MatrixLayout::cell_ranger_h5 and MatrixLayout::xenium_zarr.
TenxMatrix
The sparse matrix of a 10x file as read, before rows are named and kept: its triplets, how far they reach, and whatever names the file lists.

Functions§

build_from_zarr_matrix
Read the sparse matrix of a 10x-style Zarr store into a new backend at backend_file (write_10x_matrix), columns named by Xenium cell id when they are encoded so. Shared by data-beans from-zarr and try_open_or_convert, so both read a store alike. The caller prepares and finalizes the output (prepare_output, finalize_output).
convert_zarr_to_backend
Convert a 10x-style Zarr file (Xenium cell_feature_matrix.zarr.zip or directory) to a data-beans backend, read as data-beans from-zarr reads it with its defaults (MatrixLayout::xenium_zarr).
try_open_or_convert
Try to open a data file directly; if that fails, attempt automatic conversion from raw 10x formats (h5/h5ad, zarr/zarr.zip).
write_10x_matrix
Write m as a new backend at backend_file: rows named {id}_{name} (just id when the name is empty or repeats it; made unique) and kept by type (comma-separated, case-insensitive patterns; a file without types keeps all), columns named as the file names them. Shared by the 10x readers, so every format and entry point names and keeps rows alike.