validate_parameters {MungeSumstats}R Documentation

Ensure that the input parameters are logical

Description

Ensure that the input parameters are logical

Usage

validate_parameters(
  path,
  ref_genome,
  convert_small_p,
  convert_n_int,
  analysis_trait,
  INFO_filter,
  N_std,
  rmv_chr,
  on_ref_genome,
  strand_ambig_filter,
  allele_flip_check,
  bi_allelic_filter
)

Arguments

path

Filepath for the summary statistics file to be formatted

ref_genome

name of the reference genome used for the GWAS (GRCh37 or GRCh38)

convert_small_p

Binary, should p-values < 5e-324 be converted to 0? Small p-values pass the R limit and can cause errors with LDSC/MAGMA and should be converted. Default is TRUE.

convert_n_int

Binary, if N (the number of samples) is not an integer, should this be rounded? Default is TRUE.

analysis_trait

If multiple traits were studied, name of the trait for analysis from the GWAS. Default is NULL

INFO_filter

numeric The minimum value permissible of the imputation information score (if present in sumstatsfile). Default 0.9

N_std

numeric The number of standard deviations above the mean a SNP's N is needed to be removed. Default is 5.

rmv_chr

vector or character The chromosomes on which the SNPs should be removed. Use NULL if no filtering necessary. Default is X, Y and mitochondrial.

on_ref_genome

Binary Should a check take place that all SNPs are on the reference genome by SNP ID. Default is TRUE

strand_ambig_filter

Binary Should SNPs with strand-ambiguous alleles be removed. Default is FALSE

allele_flip_check

Binary Should the allele columns be chacked against reference genome to infer if flipping is necessary. Default is TRUE

bi_allelic_filter

Binary Should non-biallelic SNPs be removed. Default is TRUE

Value

No return


[Package MungeSumstats version 1.0.1 Index]