Coding-variant Allelic Series Test

2022-12-21

Data

To run an allelic series test, there are 4 key inputs:

The example data used below were generated using the DGP function provided with the package. The data set includes 100 subjects, 300 variants, and a continuous phenotype. The true effect sizes follow an allelic series, with magnitudes proportional to c(1, 2, 3) for BMVs, DMVs, and PTVs respectively.

set.seed(101)
n <- 100
data <- AllelicSeries::DGP(
  n = n,
  snps = 300,
  beta = c(1, 2, 3) / sqrt(n),
)

# Annotations.
anno <- data$anno
head(anno)
## [1] 0 0 0 2 1 0
# Covariates.
covar <- data$covar
head(covar)
##      int         age        sex        pc1        pc2         pc3
## [1,]   1  0.68477658 -1.1224972 -0.6807247 -0.4001798 -0.14686205
## [2,]   1 -0.39497721  0.8819621  0.4276220  0.4275115 -1.31046470
## [3,]   1 -0.23491732  0.8819621  2.6045440  1.3567071 -2.09212883
## [4,]   1  0.13831934  0.8819621  0.2811747 -0.3707890  0.07606076
## [5,]   1 -0.02007142  0.8819621  1.1725315  0.1239303 -1.46471403
## [6,]   1  1.76061280  0.8819621 -0.5597953  0.3463956  0.01463249
# Genotypes.
geno <- data$geno
head(geno[,1:5])
##      [,1] [,2] [,3] [,4] [,5]
## [1,]    0    0    0    0    0
## [2,]    0    0    0    0    0
## [3,]    0    0    0    0    0
## [4,]    0    0    0    0    0
## [5,]    0    0    0    0    0
## [6,]    0    1    0    0    1
# Phenotype.
pheno <- data$pheno
head(pheno)
## [1]  2.02718287 -0.65067678 -0.62554778  0.04889603 -1.08599635  0.74506676

The example data generated by the preceding are available under vignettes/vignette_data.

Running the alleic series test

The COding-variant Allelic Series Test (COAST) is run using the COAST function. By default, p-values for the component tests, as well as the overall omnibus test (p_omni), are returned. Inspection of the component p-values is useful for determining which model(s) drove an association. In the presence case, the association was most evident via the baseline count model (p_count).

results <- AllelicSeries::COAST(
  anno = anno,
  geno = geno,
  pheno = pheno,
  covar = covar
)
show(results)
##        p_count          p_ind    p_max_count      p_max_ind    p_sum_count 
##   7.707024e-29   6.745269e-06   4.299938e-13   6.228669e-07   6.756953e-18 
##      p_sum_ind p_allelic_skat         p_omni 
##   1.894500e-06   8.507977e-08   9.248429e-28

Test options

AllelicSeries::COAST(
  anno = anno,
  geno = geno,
  pheno = pheno,
  covar = covar,
  apply_int = TRUE
)
AllelicSeries::COAST(
  anno = anno,
  geno = geno,
  pheno = pheno,
  covar = covar,
  include_orig_skato_all = TRUE,
  include_orig_skato_ptv = TRUE,
)
AllelicSeries::COAST(
  anno = anno,
  geno = geno,
  pheno = 1 * (pheno > 0),
  covar = covar,
  is_pheno_binary = TRUE
)
AllelicSeries::COAST(
  anno = anno,
  geno = geno,
  pheno = pheno,
  covar = covar,
  return_omni_only = TRUE
)
AllelicSeries::COAST(
  anno = anno,
  geno = geno,
  pheno = pheno,
  covar = covar,
  weights = c(1, 2, 3)
)