-snp-match-fields option is ignored when updating SNP meta information

Issue #24 resolved
Sebastian Pölsterl
created an issue

Hi,

I've built qctool2 version cb1bcde93ec1 and want to update the SNP information in a GEN file using the -map-id-data information. In addition, I want to ignore the SNPID field when matching SNPs in the GEN file to the SNPs in the provided map file using -snp-match-fields position,alleles. However, it seems that the latter is ignored and has no effect.

Example

qctool_v2.0-rc1 -g example.gen -map-id-data example.map -og example_out.gen -snp-match-fields position,alleles -assume-chromosome 0

example.gen

--- chr10:152313 1152313 A C 0 1 0 0 0 1 1 0 0 1 0 0 0 1 0
--- chr10:152718 152718 G T 1 0 0 1 0 0 1 0 0 1 0 0 0 1 0
--- chr10:65209 165209 T C 0 1 0 0 1 0 0 0 1 0 1 0 1 0 0
--- chr10:219741 219741 C G 1 0 0 0 1 0 1 0 0 1 0 0 0 0 1

example.map

1 2 3 4 5 6 7 8 9 10 11 12
A-- chr10:152313 0 1152313 A C - NEW_chr10:152313 10 1152313 A C
B-- chr10:152718 0 152718 G T - NEW_chr10:152718 10 152718 G T
C-- chr10:65209 0 165209 T C - NEW_chr10:65209 10 165209 T C
--- chr10:219741 0 219741 C G - NEW_chr10:219741 10 219741 C G

example_out.gen

0 --- chr10:152313 1152313 A C 0.00000 1.00000 0.00000 0.00000 0.00000 1.00000 1.00000 0.00000 0.00000 1.00000 0.00000 0.00000 0.00000 1.00000 0.00000
0 --- chr10:152718 152718 G T 1.00000 0.00000 0.00000 1.00000 0.00000 0.00000 1.00000 0.00000 0.00000 1.00000 0.00000 0.00000 0.00000 1.00000 0.00000
0 --- chr10:65209 165209 T C 0.00000 1.00000 0.00000 0.00000 1.00000 0.00000 0.00000 0.00000 1.00000 0.00000 1.00000 0.00000 1.00000 0.00000 0.00000
10 - NEW_chr10:219741 219741 C G 1.00000 0.00000 0.00000 0.00000 1.00000 0.00000 1.00000 0.00000 0.00000 1.00000 0.00000 0.00000 0.00000 0.00000 1.00000

Only the last SNP, where SNPIDs are identical gets updated, but not the others.

Comments (2)

  1. Log in to comment