Diagnose LD mismatch using SuSiE RSS

diagnose_LD_mismatch_susie(
  region_ids,
  z_snp,
  LD_map,
  gwas_n,
  p_diff_thresh = 5e-08,
  LD_format = c("rds", "rdata", "mtx", "csv", "txt", "custom"),
  LD_loader_fun = NULL,
  snpinfo_loader_fun = NULL,
  ncore = 1,
  logfile = NULL
)

Arguments

region_ids

A vector of region IDs to run diagnosis

z_snp

A data frame with two columns: "id", "A1", "A2", "z". giving the z scores for snps. "A1" is effect allele. "A2" is the other allele.

LD_map

a data frame with filenames of LD matrices and SNP information for each of the regions.

gwas_n

integer, GWAS sample size.

p_diff_thresh

numeric, p-value threshold for identifying problematic SNPs with significant difference between observed z-scores and estimated values

LD_format

file format for LD matrix. If "custom", use a user defined LD_loader_fun() function to load LD matrix.

LD_loader_fun

a user defined function to load LD matrix when LD_format = "custom".

snpinfo_loader_fun

a user defined function to load SNP information file, if SNP information files are not in standard cTWAS reference format.

ncore

integer, number of cores for parallel computing.

logfile

the log file, if NULL will print log info on screen

Value

a list of problematic SNPs, flipped SNPs, and test statistics from susie's `kriging_rss` function