How to set only genotype to ./. based on different conditions


#1

Dear Hail team,

Based on different conditions i am trying to get my sample genotype information to missing (./.) but i want to keep the rest of the information. for example based on a condition i want my sample genotype to look ./.:40,20:55:… this way rather than just ./.

Thanks in advance :slight_smile:


#2

In this case, don’t use filter_entries, use annotate_entries to reassign the GT field:

mt = mt.annotate_entries(GT = hl.null(hl.tcall) ) # or whatever