End-to-end S-LDSC post-processing across traits, single + joint in one pass
Source:R/sldsc_wrapper.R
sldsc_postprocessing_pipeline.RdTop-level orchestration. Reads polyfun outputs (one single-target run per target plus, when available, one joint run per trait), standardizes both modes, and runs the default random-effects meta across all traits.
Usage
sldsc_postprocessing_pipeline(
trait_single_prefixes,
trait_joint_prefix,
target_anno_dir,
frqfile_dir = NULL,
plink_name = "ADSP_chr",
maf_cutoff = 0.05,
target_categories = NULL,
target_labels = NULL
)Arguments
- trait_single_prefixes
Named list. For each trait, a character vector of length \(N\) giving the polyfun output prefixes for the \(N\) single-target runs (order must match `target_categories`).
- trait_joint_prefix
Named character. For each trait, the polyfun output prefix for the joint run. Pass `NA` (or `""`) for a trait without a joint run.
- target_anno_dir
Character. Directory of target `.annot.gz` files used for `sd_C` and binary detection (typically the joint-mode dir).
- frqfile_dir
Character or NULL.
- plink_name
Character. Default `"ADSP_chr"`.
- maf_cutoff
Numeric, default `0.05`.
- target_categories
Character vector or NULL. Auto-detected from the first available run if NULL.
- target_labels
Character vector or NULL. Optional user-friendly display names for the target annotations, same length and order as the resolved `target_categories` (e.g. `c("quantile_eQTL", "eQTL")` to replace the polyfun `.results` names `c("ANNOT_1_0", "ANNOT_2_0")`). When given, every `target` column and `tau*`-block column name in the output is renamed; `params$target_categories` then holds the labels and `params$target_categories_orig` keeps the original polyfun names. When NULL (default), nothing is renamed - the original `.results` category names are used as before.