You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* HVG span (`--hvg_span`): span passed to Scanpy Seurat v3 HVG selection (default: `auto`, using `1.0` with `--hvg_batch_key` and `0.3` otherwise).
79
81
* (optional) Cell‑level metadata CSV to add after pooling (`--metadata`).
80
82
* (optional) CSV with custom QC thresholds for the GMM (`--metrics_csv`).
81
83
* CSV for manual QC cutoffs when running in `subset` mode (`--limits_csv`) (see `example_cutoffs.csv`).
@@ -455,11 +457,13 @@ This step requires the h5ad object from `finalize_qc` step.
455
457
456
458
The integration script keeps memory lower by opening the input H5AD in backed mode, reading only the retained cells and selected HVGs for scVI training, then re-reading the original object at the end to write a full-gene integrated output. The output keeps all genes for retained cells and adds the scVI embedding, neighbours, UMAP, and HVG annotations.
457
459
458
-
Note: integrated outputs may differ from previous scAutoQC releases because HVG selection is now configurable and defaults to `cell_nuclei_union`. Use `--hvg_strategy global` to select one HVG set across all retained cells.
460
+
Note: integrated outputs may differ from previous scAutoQC releases because HVG selection is now configurable and defaults to `cell_nuclei_union`. Use `--hvg_strategy global` to select one HVG set across all retained cells. Set `--hvg_batch_key <obs_column>` to run Scanpy HVG selection with `batch_key=<obs_column>`. With the default `--hvg_span auto`, the pipeline uses `span=1.0` for batch-aware HVG selection and Scanpy's `span=0.3` default otherwise.
459
461
460
462
The following preprocessing is applied before scVI training:
461
463
* Stringent doublets are removed when `--from_scautoqc true`.
462
464
* Cell-cycle genes are excluded from HVG selection when `--from_scautoqc true`.
465
+
* If `--hvg_batch_key` is set, that obs column is passed to `scanpy.pp.highly_variable_genes` as `batch_key`; leave it empty to keep the existing non-batch-aware HVG behavior.
466
+
*`--hvg_span` is passed to `scanpy.pp.highly_variable_genes` as `span`; `auto` uses `1.0` for batch-aware HVG selection to reduce LOESS near-singularity failures, while retaining Scanpy's `0.3` default when no HVG batch key is used.
463
467
* HVGs are selected with `--hvg_strategy`:
464
468
*`cell_nuclei_union` (default): calculates HVGs separately for observations annotated as `cell` and `nuclei` in `cell_or_nuclei`, then uses the union of both sets. `--n_top_genes` is applied per group, so the final union can contain more than `--n_top_genes` genes.
465
469
*`global`: ignores `cell_or_nuclei` and calculates one HVG set from all retained cells. `--n_top_genes` is the total target number of HVGs.
0 commit comments