format_data | R Documentation |
Reads in and format input data. It checks and organises columns for Slope-Hunter analyses. Infers p-values when possible from beta and se.
format_data( dat, type = "incidence", snps = NULL, snp_col = "SNP", beta_col = "BETA", se_col = "SE", pval_col = "PVAL", eaf_col = "EAF", effect_allele_col = "EA", other_allele_col = "OA", gene_col = "GENE", chr_col = "CHR", pos_col = "POS", min_pval = 1e-200, log_pval = FALSE )
dat |
Data frame. Must have header with at least the |
type |
Is this the incidence or the prognosis data that is being read in? The default is |
snps |
SNPs to extract. If NULL, then it keeps all. The default is |
snp_col |
Required name of column with SNP rs IDs. The default is |
beta_col |
Required name of column with effect sizes. The default is |
se_col |
Required name of column with standard errors. The default is |
pval_col |
Name of column with p-value (optional). The default is |
eaf_col |
Name of column with effect allele frequency (optional). The default is |
effect_allele_col |
Required for harmonisation. Name of column with effect allele. Must be "A", "C", "T" or "G". The default is |
other_allele_col |
Required for harmonisation. Name of column with non-effect allele. Must be "A", "C", "T" or "G". The default is |
gene_col |
Optional column for gene name. The default is |
chr_col |
Optional column for chromosome number. The default is |
pos_col |
Optional column for SNP position. The default is |
min_pval |
Minimum allowed p-value. The default is |
log_pval |
The p-value is -log10(P). The default is |
data frame
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.