Skip to contents

Applies the Gazal standardization \(\tau^*_C = \tau_C \cdot sd_C \cdot M_{ref} / h^2_g\) to the point and to each jackknife block. For `mode = "single"`, additionally computes EnrichStat and back-solves its standard error from polyfun's reported `Enrichment_p` using \(|Z| = \Phi^{-1}(1 - p/2)\).

Usage

standardizeSldscTrait(
  sldscData,
  trait,
  mode = c("single", "joint"),
  idx = NULL,
  sdAnnot,
  MRef,
  targetCategories = NULL
)

Arguments

sldscData

An SldscData object (the run is pulled from it via getTraitRun).

trait

Character. Trait name (a key of the SldscData traits list).

mode

Character: `"single"` or `"joint"`.

idx

Integer or NULL. For `mode = "single"`, which of the trait's single-target runs to standardize.

sdAnnot

Named numeric vector from computeSldscAnnotSd.

MRef

Scalar from computeSldscMRef.

targetCategories

Character vector or NULL. If NULL, intersects the run's `categories` with `names(sdAnnot)`.

Value

A list with `summary` (data frame), `tau_star_blocks` (matrix), `h2g`, `nBlocks`, `mode`.