multi_meta: Meta-analysis of multivariate GWAS results

Description Usage Arguments Details Examples

View source: R/multi_meta.R

Description

multi_meta returns the meta-analysis results for multivariate GWAS across different cohorts.

Usage

1
2
3
  multi_meta(files = c(), N = c(),
    output.file = "Meta_Results.txt", size.chunks = 5e+06,
    min.pop = 2, sep = "\t")

Arguments

files

A vector containing the names of the results files to meta-analyse. These can be outputs from GEMMA multivariate analysis or similar (see Details). Furthermore they can be single-chromosome or genome-wide results.

N

A vector containing sample sizes for each of the above files. This parameter is optional and is only required for computing the overall allele frequency.

output.file

The name of the output file.

size.chunks

Size of each chunk to be read and processed. Default is 5,000,000 (5 Mb). This size will require very low memory usage. Increase this parameter if more memory is allocated or if the number of cohorts is limited. Read more about the chunks in Details.

min.pop

Minimum number of populations required per SNP to compute meta-analysis. Default is 2, it can be any number up to the total number of cohorts analysed.

sep

Separator for reading input files.

Details

This function applies an inverse-variance based method to meta-analyse multivariate GWAS results. In particular, given n different cohorts, for which p phenotypes have been tested for genome-wide association, the results for each cohort will have p different effect size coefficients i.e. beta values (one per each phenotype) and a variance/covariance pxp matrix representing beta's variances and covariances. In particular, the function is built to consider the output from the GEMMA software multivariate association testing. If your output is not produced with GEMMA, the function works on any results file containing the following column names:

The function divides input files into chunks based on position. Only one chunk at a time is read and analysed; thus a limited amount of data is loaded in the workspace at one given time. Default chunk dimension is 5 Mb for which low memory is required (<250 MB for 2 cohorts). If you have larger RAM availability, sparse markers or a limited number of cohorts, change chunks' dimension from the command line.

Examples

1
2
3
4
file1=system.file("extdata", "Example_file_1.txt", package="MultiMeta")
file2=system.file("extdata", "Example_file_2.txt", package="MultiMeta")
multi_meta(files=c(file1,file2), N=c(1200,600), sep=" ",
output.file="Output_from_running_example.txt")

Example output

Loading required package: gtable
Loading required package: grid
There were 50 or more warnings (use warnings() to see the first 50)

MultiMeta documentation built on May 2, 2019, 9:11 a.m.