Skip to contents

This vignette runs a colocalization analysis on a pair of SuSiE-suite fine-mapping fits with susieR::susie_post_outcome_configuration(method = "coloc_pairwise"), a port of the coloc::coloc.bf_bf pairwise-ABF recipe maintained inside susieR. Calling the susieR port keeps the workflow self-contained and adds no soft dependency on the coloc package. The recipe applies to any pair of susie-class fits (susieR::susie(), mfsusieR::fsusie(), mfsusieR::mfsusie(), mvsusieR::mvsusie(), susieR::susie_rss()) because each returns the (class = "susie", $sets$cs_index, $lbf_variable) triple that susie_post_outcome_configuration() reads. susie_rss() covers the GWAS summary-statistics case.

We illustrate with fsusie() (single-outcome functional fine-mapping); mfsusie() works the same way when both fits cover multiple outcomes. For pre-fit covariate adjustment, see the covariates vignette.

Data

data(N3finemapping)
X <- N3finemapping$X[, seq_len(150)]
n <- nrow(X); p <- ncol(X); T_m <- 64
colnames(X) <- paste0("SNP", seq_len(p))
positions <- seq_len(T_m)
shape  <- exp(-((positions - T_m / 2)^2) / (2 * (T_m / 6)^2))
beta1  <- matrix(0, p, T_m); beta1[42, ] <- 1.2 * shape
beta2  <- matrix(0, p, T_m); beta2[42, ] <- 0.9 * shape         # shared causal
beta3  <- matrix(0, p, T_m); beta3[88, ] <- 0.9 * shape         # distinct
Y1 <- X %*% beta1 + matrix(rnorm(n * T_m, sd = 0.4), n)
Y2 <- X %*% beta2 + matrix(rnorm(n * T_m, sd = 0.4), n)
Y3 <- X %*% beta3 + matrix(rnorm(n * T_m, sd = 0.4), n)

Fine-mapping

fit1 <- fsusie(Y1, X, pos = positions, verbose = FALSE)
fit2 <- fsusie(Y2, X, pos = positions, verbose = FALSE)
fit3 <- fsusie(Y3, X, pos = positions, verbose = FALSE)

Colocalization

susie_post_outcome_configuration(list(fit1, fit2), method = "coloc_pairwise") reads the credible-set indices from each fit’s $sets$cs and the per-effect log-Bayes-factor matrix from $lbf_variable. Both are populated by fsusie() / mfsusie() on the standard fit path, so the call is a one-liner per pair of fits. The returned $coloc_pairwise data.frame reports the posterior probabilities of five hypotheses for each pair of credible sets:

meaning
PP.H0 no causal in either trait
PP.H1 causal in trait 1 only
PP.H2 causal in trait 2 only
PP.H3 causal in both, but at distinct variants
PP.H4 shared causal variant

hit1 and hit2 name the lead variant in each fit; l1 and l2 are the credible-set indices being compared; trait1 and trait2 index the input fits.

Shared causal signals

fit1 and fit2 were simulated with the same causal SNP at SNP42. The pairwise summary should put nearly all posterior mass on PP.H4 (shared causal):

res_shared <- susieR::susie_post_outcome_configuration(
  list(fit1, fit2), method = "coloc_pairwise")
res_shared$coloc_pairwise
##    trait1  trait2 l1 l2  hit1  hit2 PP.H0         PP.H1         PP.H2 PP.H3
## 1 trait_1 trait_2  1  1 SNP42 SNP42     0 6.789301e-151 7.082075e-208     0
##   PP.H4
## 1     1

PP.H4 is essentially 1 and hit1 == hit2 == SNP42, matching the simulation.

Distinct causal signals

fit1 carries a signal at SNP42; fit3 carries one at SNP88. The pairwise summary should put posterior mass on PP.H3 (both have a causal, but at different variants):

res_distinct <- susieR::susie_post_outcome_configuration(
  list(fit1, fit3), method = "coloc_pairwise")
res_distinct$coloc_pairwise
##    trait1  trait2 l1 l2  hit1  hit2 PP.H0 PP.H1         PP.H2 PP.H3
## 1 trait_1 trait_2  1  1 SNP42 SNP88     0     0 3.541038e-205     1
##           PP.H4
## 1 2.243415e-208

PP.H3 is essentially 1, with hit1 = SNP42 and hit2 = SNP88.

Notes

The pairwise-ABF recipe assumes the user already has a pair of fine-mapping fits, possibly from different SuSiE-suite packages. When subject-level data is available for every outcome, the natural alternative is mfsusie() jointly across them: the multi-outcome fit shares signal across modalities and identifies per-outcome and shared credible sets in one pass without a post-hoc combination step. The pairwise recipe is essential when one or more inputs are summary-statistics fits, e.g., a GWAS susie_rss() fit colocalized against a molecular-QTL fsusie() fit, where the underlying individual-level data is not available. Joint mfsusie() fine-mapping that takes GWAS summary statistics as one of its outcomes is future work.

For colocalization across more than two outcomes, see the multi-outcome intro; the joint fit avoids the post-hoc combine but rides on mfSuSiE’s modeling assumptions and is less modular than integrating separate SuSiE-suite fits.

Session info

This is the version of R and the packages that were used to generate these results.

## R version 4.4.3 (2025-02-28)
## Platform: x86_64-conda-linux-gnu
## Running under: Ubuntu 24.04.4 LTS
## 
## Matrix products: default
## BLAS/LAPACK: /home/runner/work/mfsusieR/mfsusieR/.pixi/envs/r44/lib/libopenblasp-r0.3.32.so;  LAPACK version 3.12.0
## 
## locale:
##  [1] LC_CTYPE=C.UTF-8       LC_NUMERIC=C           LC_TIME=C.UTF-8       
##  [4] LC_COLLATE=C.UTF-8     LC_MONETARY=C.UTF-8    LC_MESSAGES=C.UTF-8   
##  [7] LC_PAPER=C.UTF-8       LC_NAME=C              LC_ADDRESS=C          
## [10] LC_TELEPHONE=C         LC_MEASUREMENT=C.UTF-8 LC_IDENTIFICATION=C   
## 
## time zone: Etc/UTC
## tzcode source: system (glibc)
## 
## attached base packages:
## [1] stats     graphics  grDevices utils     datasets  methods   base     
## 
## other attached packages:
## [1] susieR_0.16.1  mfsusieR_0.0.2
## 
## loaded via a namespace (and not attached):
##  [1] sass_0.4.10           generics_0.1.4        ashr_2.2-63          
##  [4] lattice_0.22-9        digest_0.6.39         magrittr_2.0.5       
##  [7] evaluate_1.0.5        grid_4.4.3            RColorBrewer_1.1-3   
## [10] fastmap_1.2.0         plyr_1.8.9            jsonlite_2.0.0       
## [13] Matrix_1.7-5          reshape_0.8.10        mixsqp_0.3-54        
## [16] scales_1.4.0          truncnorm_1.0-9       invgamma_1.2         
## [19] textshaping_1.0.5     jquerylib_0.1.4       cli_3.6.6            
## [22] crayon_1.5.3          zigg_0.0.2            rlang_1.2.0          
## [25] deconvolveR_1.2-1     LaplacesDemon_16.1.8  splines_4.4.3        
## [28] cachem_1.1.0          yaml_2.3.12           otel_0.2.0           
## [31] ebnm_1.0-55           tools_4.4.3           SQUAREM_2026.1       
## [34] parallel_4.4.3        dplyr_1.2.1           wavethresh_4.7.3     
## [37] ggplot2_4.0.3         Rfast_2.1.5.2         vctrs_0.7.3          
## [40] R6_2.6.1              matrixStats_1.5.0     lifecycle_1.0.5      
## [43] fs_2.1.0              htmlwidgets_1.6.4     MASS_7.3-65          
## [46] trust_0.1-9           ragg_1.5.2            irlba_2.3.7          
## [49] pkgconfig_2.0.3       desc_1.4.3            RcppParallel_5.1.11-2
## [52] pkgdown_2.2.0         bslib_0.10.0          pillar_1.11.1        
## [55] gtable_0.3.6          glue_1.8.1            Rcpp_1.1.1-1.1       
## [58] systemfonts_1.3.2     xfun_0.57             tibble_3.3.1         
## [61] tidyselect_1.2.1      dichromat_2.0-0.1     knitr_1.51           
## [64] farver_2.1.2          htmltools_0.5.9       rmarkdown_2.31       
## [67] compiler_4.4.3        S7_0.2.2              horseshoe_0.2.0