View source: R/multivariable_mr.R
mv_extract_exposures_local | R Documentation |
Allows you to read in summary data from text files to format the multivariable exposure dataset.
mv_extract_exposures_local(
filenames_exposure,
sep = " ",
phenotype_col = "Phenotype",
snp_col = "SNP",
beta_col = "beta",
se_col = "se",
eaf_col = "eaf",
effect_allele_col = "effect_allele",
other_allele_col = "other_allele",
pval_col = "pval",
units_col = "units",
ncase_col = "ncase",
ncontrol_col = "ncontrol",
samplesize_col = "samplesize",
gene_col = "gene",
id_col = "id",
min_pval = 1e-200,
log_pval = FALSE,
pval_threshold = 5e-08,
plink_bin = NULL,
bfile = NULL,
clump_r2 = 0.001,
clump_kb = 10000,
pop = "EUR",
harmonise_strictness = 2
)
filenames_exposure |
Filenames for each exposure dataset. Must have header with at least SNP column present. Following arguments are used for determining how to read the filename and clumping etc. |
sep |
Specify delimeter in file. The default is space, i.e. |
phenotype_col |
Optional column name for the column with phenotype name corresponding the the SNP. If not present then will be created with the value |
snp_col |
Required name of column with SNP rs IDs. The default is |
beta_col |
Required for MR. Name of column with effect sizes. THe default is |
se_col |
Required for MR. Name of column with standard errors. The default is |
eaf_col |
Required for MR. Name of column with effect allele frequency. The default is |
effect_allele_col |
Required for MR. Name of column with effect allele. Must be "A", "C", "T" or "G". The default is |
other_allele_col |
Required for MR. Name of column with non effect allele. Must be "A", "C", "T" or "G". The default is |
pval_col |
Required for enrichment tests. Name of column with p-value. The default is |
units_col |
Optional column name for units. The default is |
ncase_col |
Optional column name for number of cases. The default is |
ncontrol_col |
Optional column name for number of controls. The default is |
samplesize_col |
Optional column name for sample size. The default is |
gene_col |
Optional column name for gene name. The default is |
id_col |
Optional column name to give the dataset an ID. Will be generated automatically if not provided for every trait / unit combination. The default is |
min_pval |
Minimum allowed p-value. The default is |
log_pval |
The pval is -log10(P). The default is |
pval_threshold |
Default= |
plink_bin |
If |
bfile |
If this is provided then will use the API. Default = |
clump_r2 |
Default= |
clump_kb |
Default= |
pop |
Which 1000 genomes super population to use for clumping when using the server |
harmonise_strictness |
See action argument in |
Note that you can provide an array of column names for each column, which is of length filenames_exposure
List
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.