Skip to content

Commit b3b36af

Browse files
Will-Tylerjeromekelleher
authored andcommitted
Add compute_laa_field description
1 parent 0c83b21 commit b3b36af

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

bio2zarr/vcf2zarr/icf.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -491,6 +491,14 @@ def sanitise_value_int_2d(buff, j, value):
491491

492492

493493
def compute_laa_field(variant) -> np.ndarray:
494+
"""
495+
Computes the value of the LAA field for each sample given a variant.
496+
497+
The LAA field is a list of one-based indices into the ALT alleles
498+
that indicates which alternate alleles are observed in the sample.
499+
500+
This method infers which alleles are observed from the GT, AD, and PL fields.
501+
"""
494502
sample_count = variant.num_called + variant.num_unknown
495503
alt_allele_count = len(variant.ALT)
496504
allele_count = alt_allele_count + 1

0 commit comments

Comments
 (0)