Bulk Export (dump)
afquery dump exports allele frequency data to CSV. It supports filtering by region and disaggregating output by sex, technology, or phenotype group.
Basic Usage
Export all variants to stdout:
Write to a file:
AC > 0 filter
By default dump exports only variants with AC > 0. Variants at covered positions with no carriers are omitted. Use --all-variants to include AC=0 rows, or afquery query --locus to verify coverage at a specific position.
Filter by Region
Export a single chromosome:
Export a specific region:
Positions are 1-based, inclusive on both ends.
Sample Filtering
Apply the same sample filters as query:
afquery dump --db ./db/ \
--phenotype E11.9 \
--sex female \
--tech wgs \
--output diabetic_female_wgs.csv
Disaggregate Output
All three disaggregation modes work on the same principle: add stratified columns alongside the totals. They can be combined in a single command.
Base columns (always present):
Add separate columns for male and female:
Output columns:
Add separate columns per sequencing technology:
Output columns include AC_wgs, AN_wgs, AF_wgs, N_HET_wgs, N_HOM_ALT_wgs, N_HOM_REF_wgs, N_FAIL_wgs, AC_wes_v1, AN_wes_v1, etc. (one group of seven columns per registered technology).
Add separate columns for specific phenotype groups:
Output includes AC_E11.9, AN_E11.9, AF_E11.9, N_HET_E11.9, N_HOM_ALT_E11.9, N_HOM_REF_E11.9, N_FAIL_E11.9, AC_I10, etc.
Parallelism
Use multiple threads for faster export:
Full Option Reference
See CLI Reference → dump.
Next Steps
- Cohort Stratification — systematic cross-group AF comparison on specific loci
- Sample Filtering — filter syntax shared across query, annotate, and dump
- Performance Tuning — thread tuning for large export jobs