brentp / somalier

fast sample-swap and relatedness checks on BAMs/CRAMs/VCFs/GVCFs... "like damn that is one smart wine guy"
MIT License
262 stars 35 forks source link

Add argument to select AF/AN field for find-sites #111

Closed Balthasar-eu closed 1 year ago

Balthasar-eu commented 1 year ago

This adds two command line options to find sites: --AN-field --AF-field which allow the selection of the AN and AF field in the INFO column of the vcf. This is useful, because gnomad, for example, has population specific AF/AN fields. The default behaviour is unchanged.

Unrelated, but I am also wondering, why select-sites excludes variants with a Cytosine in ref on autosomes, see https://github.com/brentp/somalier/blob/master/src/somalierpkg/findsites.nim#L135

brentp commented 1 year ago

Thanks! The cytosine check is there so that the resulting sites file will work on bisulfite-seq data where unmethylated C's are converted to T's.