Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a flag to omit homozygous reference calls on vcf_to_bq import #661

Open
mbookman opened this issue Sep 9, 2020 · 0 comments
Open

Add a flag to omit homozygous reference calls on vcf_to_bq import #661

mbookman opened this issue Sep 9, 2020 · 0 comments

Comments

@mbookman
Copy link
Contributor

mbookman commented Sep 9, 2020

Output from joint genotyping is a nice squared off matrix of variant rows and callset (sample) columns.
It is typically the case that around 90% of such data is high quality calls of homozygous reference.
This additional 90% of data is expensive to insert, store, and query, and often fundamentally unused.

If one were to only insert only the variant calls and no-calls, and you know your list of samples, you can infer for each call which samples were homozygous reference.

On one test dataset, importing a subset of total variants, we observed that dropping homozygous reference calls reduced import cost around 75%. Further it reduced the storage size (and hence cost) about 90%. The reduced storage size also means similar reduction in query costs. Other datasets will vary in how they are impacted.

I propose a new flag:

--hom-ref-disposition=['keep', 'drop']

with the default today being keep. This could be expanded in the future to allow for keeping the homozygous reference calls, but perhaps only the name (not the whole call record) or a few key fields [name, GQ, AD] in a separate hom_ref column.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant