chorscroft / MR-and-selection

Documents and code for the MR and selection project
https://chorscroft.github.io/MR-and-selection/
0 stars 1 forks source link

Meta-analysis of male and female number of children #4

Open explodecomputer opened 3 years ago

explodecomputer commented 3 years ago

So the objective here is to take the GWAS for males and GWAS for females, and create a new one which has the same number of SNPs but a single combined effect for each SNP. In doing so we can also test each SNP whether they have different effects in males and females using a heterogeneity test statistic.

  1. Get the GWAS summary data for the male and female traits

You should be able to download them from here: https://gwas.mrcieu.ac.uk/datasets/ukb-b-1209/ https://gwas.mrcieu.ac.uk/datasets/ukb-b-2227/

  1. Extract from gwas-vcf format to plain text format e.g. https://github.com/MRCIEU/gwas2vcf/blob/master/README.md#export-to-nhgri-ebi-gwas-catalog-format

  2. Use a tool like METAL to meta-analyse the https://genome.sph.umich.edu/wiki/METAL_Documentation What you do is create a configuration text file that specifies the files, the columns in the files, and what analysis to run. Then you pass that file to the METAL binary

    • Meta-analyse betas and SE rather than p-values and sample size (e.g. use the "SCHEME STDERR" option)
    • Genomic control OFF
    • Use AVERAGEFREQ ON
    • use "ANALYSE HETEROGENEITY" instead of ANALYSE, to get the heterogeneity test statistics
  3. Once you have the new GWAS dataset, that can be uploaded to OpenGWAS using the GwasDataImport R package: https://mrcieu.github.io/GwasDataImport/articles/import_pipeline.html Note that this won't be able take the heterogeneity results, so if we are to use any of that info at some point it will have to be from the meta-analysis results file directly.

chorscroft commented 3 years ago

I believe this has now gone through successfully! If you agree, we can close this issue :)