Repository navigation
cellink works on HiData from the HiData package, which continues DonorData
under a new name. Names and the file format change; every analysis gives the same results.
Changed
- Requires hidata 0.1.0 or newer instead of donordata.
cellink.DonorDataandcellink.DonorDataSchemaErrorare
cellink.HiDataandcellink.HiDataSchemaError. - The donor level
dd.Dis the group levelhd.G, which holds the genotypes with one row per donor, and the other
names change as listed in the HiData changelog, for
examplesel(G_obs=..., G_var=...),n_groupsand the level names"group","subgroup"and"cell". Columns such
asdonor_idkeep their names, soHiData(G=..., C=..., group_id="donor_id")builds what
DonorData(D=..., C=...)built. - The argument
ddishdinvalidate,pl.expression_by_genotype,tl.external.run_tensorqtl,
tl.external.run_dense_trans_scan,tl.external.run_jaxqtl,tl.external.run_saigeqtl,
tl.external.make_group_file,tl.external.run_mixmil,tl.external.calculate_pcs,tl.external.calculate_ld,
tl.external.estimate_ld_scores_from_hidata,tl.external.make_annot_from_hidata,
tl.external.compute_ld_scores_with_annotations_from_hidataandtl.external.run_magma_pipeline, and
ld_source="dd_genotypes"oftl.external.run_magma_pipelineisld_source="hd_genotypes". io.read_dd,io.read_h5_dd,io.read_zarr_dd,io.write_dd,io.write_h5_ddandio.write_zarr_ddare
io.read_hd,io.read_h5_hd,io.read_zarr_hd,io.write_hd,io.write_h5_hdandio.write_zarr_hd. They write
the HiData format, with the genotypes of a 2-bit store inG/X;x_chunkstakes the key"G"andio.write_hd
appends.hd.h5or.hd.zarr.tl.external.estimate_ld_scores_from_donor_data,tl.external.make_annot_from_donor_dataand
tl.external.compute_ld_scores_with_annotations_from_donor_dataaretl.external.estimate_ld_scores_from_hidata,
tl.external.make_annot_from_hidataandtl.external.compute_ld_scores_with_annotations_from_hidata.pp.donor_level_obs_filterandpp.donor_level_var_filterarepp.group_level_obs_filterand
pp.group_level_var_filter, withgroup_level_keyandgroup_level_values.cellink.mland themlextra are removed.MILDataset,mil_collate_fn,get_arrayandml.DonorMILModel, now
GroupMILModel, are inhidata.ml(pip install "hidata[ml]"), see the
HiData tutorial.MILDatasettakes and yields
group_*fields, for examplesplit_groupsandgroup_labels_key, andGroupMILModeltakesn_input_group
instead ofn_input_donor. The tutorial on dataloaders is replaced by the HiData tutorial.target_level="donor"ofat.get_model_matrix,at.GWAS,at.StructLMMandat.Skat.run_testis
target_level="group".- The formula functions
dmean,dmax,dmediananddfirstofat, which aggregate cells per group, are
group_mean,group_max,group_medianandgroup_first. n_donorsofsim_adata,sim_gdataandsim_mudataincellink._core.dummy_dataisn_groups.resources.get_dummy_onek1kdownloadsdummy_onek1k_dataset.hd.h5, the same data in the HiData format, whose
G.uns["dummy_onek1k"]hasn_groupsandmax_cells_per_group;docs/tutorials/generate_dummy_onek1k.pytakes
--n_groupsand--max_cells_per_group.- The VEP configs
vep,vep_offlineandvep_offline_localoftl.run_vepannotate GRCh38, the build of OneK1K
and the dummy dataset, instead of GRCh37, and the offline configs use CADD v1.7 for GRCh38. at.fetch_slotsearches the levels("G", "C")by default.DAnnincellink._coreholds cellink's donor columns (donor_id,donor_family_id,donor_paternal_id,
donor_maternal_idandsex) and no longer the field names ofMILDataset.- The tutorial DonorData basics is HiData basics.
Added
io.read_*_hdread the files and stores written by donordata and by cellink 0.1.0, including 2-bit genotype stores,
and the older cellink files with the donor level inG. Writing such an object again stores it in the HiData format.