Genetic-correlation workflow

Use checked summary-statistics data frames and explicit LD inputs with gcorr.

Prepare summary statistics

The input is an ordinary data frame with qgg-style names. When a Glist reference is available, gbase::checkStat() performs marker mapping, allele alignment and explicit QC. A task package never imports gsuite.

library(gbase)
library(gcorr)

markers <- paste0("rs", 1:20)
statistics <- data.frame(rsids = markers, chr = "1", pos = 1:20,
  ea = "A", nea = "G", stat = seq(1.5, 2.5, length.out = 20),
  n = 10000)

Fit a focused method

ld_scores <- setNames(seq(1, 2, length.out = 20), markers)
blocks <- setNames(rep(paste0("b", 1:5), each = 4), markers)

fit <- gcorr_ldsc(statistics, ld_scores, blocks,
  marker_count = 50000)
fit$estimates

Use gcorr_gnova() or gcorr_sumher() when their explicit score and annotation inputs are available. Regional workflows pass a sparse-LD Glist and named marker regions to gcorr_prepare_regions(), then call a focused HESS, SUPERGNOVA, LAVA or HDL-L function. See the complete method contract.