snapatac2.ex.export_bed#
- snapatac2.ex.export_bed(adata, groupby, selections=None, ids=None, out_dir='./', prefix='', suffix='.bed.gz')[source]#
Export base-resolution TN5 insertion sites as BED format file.
- Parameters:
adata (
AnnData|AnnDataSet) – The (annotated) data matrix of shapen_obsxn_vars. Rows correspond to cells and columns to regions.groupby (
str|list[str]) – Group the cells. If astr, groups are obtained from.obs[groupby].selections (
Optional[list[str]]) – Export only the selected groups.ids (
Union[str,list[str],None]) – Cell ids add to the bed records. IfNone,.obs_namesis used.out_dir (
Path) – Directory for saving the outputs.prefix (
str) – Text added to the output file name.suffix (
str) – Text added to the output file name.
- Returns:
A dictionary contains
(groupname, filename)pairs. The file names are formatted as{prefix}{groupname}{suffix}.- Return type: