Move some qQTLR functions back to pecotmr for more general interests#472
Merged
danielnachun merged 6 commits intomainfrom Apr 18, 2026
Merged
Move some qQTLR functions back to pecotmr for more general interests#472danielnachun merged 6 commits intomainfrom
danielnachun merged 6 commits intomainfrom
Conversation
Extracted from qQTLR's quantile_twas_weight.R to let qQTLR (and other downstream packages) consume these as library code instead of carrying their own copies. Four new helpers live in R/LD.R: - ld_prune_by_correlation (exported): hclust/cutree-based |cor| prune - enforce_design_full_rank (exported): QR-pivot iterative rank enforcement with a ld_prune_by_correlation fallback - drop_collinear_columns (internal): strategy-based single-column removal helper used by enforce_design_full_rank - ld_clump_by_score (exported): thin wrapper around bigsnpr::snp_clumping that handles FBM.code256 conversion and single-variant edge case All message() calls now gated behind verbose = FALSE (default silent). bigsnpr and bigstatsr added to Suggests; both use requireNamespace guards. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Small internal helper so pecotmr::twas_pipeline and qQTLR::quantile_twas_pipeline produce byte-identical per-(context, study) rows from twas_analysis() output. No new export, no NAMESPACE churn. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
ff0f8a7 to
d0b20bb
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #472 +/- ##
===========================================
+ Coverage 27.48% 83.61% +56.12%
===========================================
Files 32 35 +3
Lines 4377 6682 +2305
===========================================
+ Hits 1203 5587 +4384
+ Misses 3174 1095 -2079 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Rename along the move to make it more informative.