New features:
- --vcf/--bcf now support VCFv4.4+ GT phasing-prefixes (e.g. '|0/1', '/0|1', '|1'; a call is treated as phased only if both alleles are).
- Speedups for handling of .pvar files with wide INFO columns, import of GT-only VCF files, --pca approx, and --parallel + --make-rel/--make-grm-....
Bugfixes:
- --make-pgen/--make-bed with --set-me-missing or --zero-cluster: a variant where every heterozygous call was phased could lose all of its phase information.
- --flip-subset on multiallelic variants could produce invalid output, a spurious "Variant record size exceeds ~4 GiB" error, or a crash.
- --set-invalid-haploid-missing did not handle female ALT2+ chrY calls properly.
- Under some circumstances (--sort-vars, multiallelic split, relatively low memory), --make-pgen had an undersized-for-worst-case (huge fraction of ALT2+ alleles) write buffer for variant-blocks containing multiallelic variants.
- --sort-vars with an INFO column too large to keep in memory: the temporary-file path overran its workspace, corrupting variant IDs and INFO strings; the output .pvar could grow without bound. With more than 240 temporary files, a race could also cause open failures or wrong INFO strings.
- --bcf with --vcf-min-gq/--vcf-min-dp: crashed when the first sample had a phased diploid call.
- --bcf: in files written by htslib 1.22+ from VCFv4.4+ headers (and all files written by htslib 1.23+), haploid calls were misread without error (in all-haploid records, 0 became a het and 1 became missing). Records with a GT phasing prefix (e.g. '|0/1') were also falsely rejected as polyploid.
- --bcf on 32-bit builds: in records where every call was haploid and biallelic (e.g. chrY), each genotype was shifted by one sample.
- --vcf/--bcf 'dosage=': a record with neither GT nor the requested dosage field (e.g. a GP-only line under dosage=DS) now imports as missing calls. --vcf previously parsed the first FORMAT subfield as GT (bogus hardcalls or a spurious "invalid GT field" error), and --bcf crashed.
- .bgen v1.2+ import: two of every 2^{bits+1}-1 possible dosage values (at every bit depth) were rounded up by one 1/16384 step when they should have been rounded down.
- .bgen import: a header that understated the variant count silently dropped the trailing variants, even without --lax-bgen-import. This is now an error.
- .pvar ##chrSet lines with PAR1 and PAR2 (which plink2 writes itself, including during VCF import): PAR1 variants caused a segfault, PAR2 variants were rejected, VCF import with --human/--dog/etc. failed on PAR2 data, and ##chrSet lines were written without PAR2.
- --rename-chrs: renaming onto a name another chromosome already had crashed or wrote inconsistent output (now an error). The flag was silently ignored when the input had split chromosomes, and old ##contig lines were left in the output .pvar (they now follow the rename).
- --pmerge[-list] on 32-bit builds: concatenation detection compared positions without chromosomes, which could produce an unsorted .pvar, or a spurious "under development" error with --merge-max-alleles.
- --glm permutation tests: linear and Firth regression crashed when chrY was present and chrX used the same samples and covariates as the autosomes (e.g. with 'sex'). Adaptive permutation skipped stopping checks for the later alleles of multiallelic variants. Exact ties between the original and permuted statistics were counted as 0 or 1 instead of 1/2, shifting EMP1 by up to half the tie count with discrete phenotypes.
- --clump-bins: values in decreasing order were accepted, producing wrong bin counts.
- --mach-r2-filter with no arguments had no effect (the documented 2.0 maximum was not set).
- --ld-score: the default 1 cM window excluded variants exactly 1 cM away (an explicit "--ld-score-window-cm 1" included them).
- --cm-map with a '@' pattern: when no matching file existed, plink2 reported "0 chromosomes updated" and exited normally. This is now an error.
- --indv without a SID now matches every SID, like a --keep file without a SID column. It previously required SID '0'.
- --pgen-info on a .pgen without a .pvar: when multiallelic variants were present and phase/dosage data wasn't, the maximum allele count was reported as 2.
- --validate rejected some valid .pgen files, including those with an external .pgi index, and fixed-width files whose .pvar lists an unobserved ALT allele.