Skip to content

Commit 70ba202

Browse files
committed
Updated logic for simple variant extraction
Updated the simple variant extraction logic for the case where vcf file isn't tabix indexed to also consider the length of the REF allele.
1 parent 73e3a1d commit 70ba202

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

vcf2fhir/json_generator.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@ def _get_fhir_json(
210210
not conversion_region or
211211
conversion_region[
212212
record.CHROM,
213-
record.POS - 1: record.POS
213+
record.POS - 1: (record.POS + len(record.REF) - 1)
214214
].empty is False):
215215
_add_record_variants(
216216
record, ref_seq, patientID, fhir_helper, ratio_ad_dp)

0 commit comments

Comments
 (0)