Closed pubTools closed 1 year ago
There are several tools to transform your summary statistics into the "munged" format required by the ldsc tools. Some examples include:
munge_sumstats.py
(original python script provided by the ldsc
authors): https://github.com/bulik/ldscMungeSumstats
(package for R): https://neurogenomics.github.io/MungeSumstats/articles/MungeSumstats.htmlmunge
(function from the GenomicSEM R package): https://github.com/GenomicSEM/GenomicSEMIf I have a GWAS dataframe which includes A1 A2 SNP N FRE and so on, could I use the math (Z=beta/sebeta) to calulate the Z, instead of using the MungeSumstats packages ? That correct ?
Mathematically that calculation of Z-score is correct. However, because the Z-scores are signed, you'll want to ensure your alleles correspond to those used in the reference file (and the sign of the Z-score is adjusted accordingly. The munge functions referenced above perform several checks of the data (see: https://github.com/GenomicSEM/GenomicSEM/blob/master/R/munge_main.R), and using them is strongly encouraged.
thanks for your excellent job!
for example: from
to
![eb834c42f8ef8f52e3a84ca6bee7970](https://github.com/mglev1n/ldscr/assets/39917104/d70cbcb0-db70-455c-832a-beaa3d14bff0)