Releases: chrchang/plink-ng
--glm logistic/Firth convergence bugfix
This fixes a --glm logistic/Firth convergence bug that affected the hethom/dominant/recessive/hetonly modes.
--export bgen chrX/chrY bugfix, semver
This fixes a bug in --export bgen-1.{2,3}'s behavior on chrX and chrY, where data for the last few samples might not be properly exported (possibly resulting in an invalid .bgen).
In addition:
- "requires an alpha 6 or later build" error messages are now printed when appropriate.
- The version string has been reformatted to adhere to the Semantic Versioning 2.0.0 spec.
- The --lax-bgen-import flag has been backported.
--glm no-firth covariate preprocessing bugfix
This backports the --glm no-firth covariate-preprocessing bugfix which was committed to the main branch on 23 Nov 2023.
Alpha 5.13: .map/.ped comment lines, no-0/0 VCF-import warning
Bugfixes:
- .map/.ped import now allows comment lines, as originally specified in the PLINK 1.0 documentation.
- "--export bgen-1.{2,3}" no longer generates an invalid .bgen when the sample-ID block must be omitted due to otherwise exceeding the size limit.
- BgzfFlush() and BgzfFlushTry() in include/plink2_bgzf.h should work properly again.
This also adds a warning when it looks like GATK GenotypeGVCFs needs to be rerun with --include-non-variant-sites, along with the --vcf-allow-no-nonvar flag to suppress it.
--maj-ref (without 'force') bugfix
- --maj-ref (without 'force') now behaves as documented.
- --merge-max-alleles is accepted as an alias for --merge-max-allele-ct.
Minor bugfixes, .pgen forward-compatibility
Bugfixes include:
- --update-sex no longer forgets to print an error message when file-open fails.
- --no-categorical no longer causes a segfault or assertion failure when the first nonheader line of a phenotype/covariate file has a category name.
- --pgen-info now writes to stdout instead of stderr.
This also makes the .pgen reader compatible with the header/footer extensions permitted by the May 2024 .pgen specification update, and backports the --set-invalid-haploid-missing and --neg9-pheno-really-missing flags.
Alpha 5.10: multithreaded --make-bed >260k-sample bugfix
This fixes a multithreaded --make-bed integer-overflow bug that could result in data corruption when writing >260k samples.
Apple clang 15.0 miscompilation
Steps that are likely to reproduce the issue on my M2 Mac, with Apple Clang 15.0 installed:
- Install plink 1.9 somewhere on the system PATH, either by downloading a binary from https://www.cog-genomics.org/plink/1.9/ , or following the compilation instructions in this repo.
- Navigate to the 2.0/build_dynamic subdirectory.
- Edit the right side of the "DEBUG=" line of the Makefile to have "-g".
- Append "-DNO_UNALIGNED" to the right side of the first "BASEFLAGS" line. (Not strictly necessary, but rules out some possible causes.)
- Make.
- Navigate to the 2.0/Tests subdirectory.
- Execute "./run_tests.sh ../build_dynamic" from there. You should get the following error: "./run_tests.sh: line 124: 12789 Segmentation fault: 11 $1/plink2 $2 $3 --bfile plink1_data --maf 0.02 --pheno pheno_qt.txt --glm allow-no-covars --out plink2_glm"
If necessary, I can provide the four input files for the failing command (plink1_data.bed, plink1_data.bim, plink1_data.fam, pheno_qt.txt) so the other test logic can be skipped.
The issue does not appear with Homebrew clang 16.0.6, or gcc 9.4.0 on Linux.
When I run under lldb, the segmentation fault is attributed to line 1224 of plink2_glm_linear.cc . But if I try to evaluate the supposedly problematic "xtx_inv[pred_uidx * (cur_predictor_ct + 1)]" expression in lldb after the crash, it has the value I was expecting. I tried setting a breakpoint at line 1223 while appending "--threads 1" to the plink2 command line, and then single-stepping through the assembly instructions until the crash; I observed that the assembly code thinks xtx_inv is at a slightly different address than lldb does, loads garbage from its address, and triggers a crash on dereference. The exact garbage can vary.
(update, 9 Oct 2023: this miscompilation does not happen with Xcode 15.1 beta, and there is now a test in the main branch that is likely to catch a recurrence of the issue.)
1.90 beta 5
This fixes a major .ped merge bug. (.bed merge was unaffected by this bug.)
1.90 beta 4, 2.0 public alpha
v1.90b4 move .gitignore too