bvilhjal / ldpred

MIT License
96 stars 57 forks source link

Duplicate error with coord_genotypes.py #34

Closed seunghun23 closed 5 years ago

seunghun23 commented 5 years ago

Hi,

Thank you for developing a great tool for PRS calculation. I ran the coord_genotypes.py script with a bed file of 1000 genome data as a LD reference genotype file and encountered following errors Working on chromsome: chrom_2 Traceback (most recent call last): File "coord_genotypes.py", line 1836, in <module> main() File "coord_genotypes.py", line 1824, in main hdf5_file=h5f, min_maf=p_dict['maf'], skip_coordination=p_dict['skip_coordination']) File "coord_genotypes.py", line 1183, in coordinate_genot_ss assert len(g_sid_set) == len(g_sids), 'Some duplicates?' AssertionError: Some duplicates?

Could you help me on this error?

Thanks, SH

seunghun23 commented 5 years ago

Hi again,

I figured out that the error above was due to duplicate SNPs in the 1000 genome vcf, so I made a new plink files without duplicate SNPs and that fixed the problem. However, I'm not getting an IndexError. Could you tell me how to fix this?

image

bvilhjal commented 5 years ago

Hi, I am sorry for the slow reply on this. It seems like you have too few SNPs for LDpred to make sense. I do however also agree that the error messaging could be a lot better.

seunghun23 commented 5 years ago

Hi bvilhjal, thank you for the reply. Is there a minimum number of SNPs for LDpred to run? I am using GWAS summary statistics from GWAS Catalogue, and for many phenotypes I'm looking at, number of SNPs are less than 100

-SH

bvilhjal commented 5 years ago

I recommend something between 100K and 2M SNPs. You can find links to summary statistics on LD Hub (http://ldsc.broadinstitute.org/ldhub/) and other places.

seunghun23 commented 5 years ago

Thanks a lot for introducing a great resource!

On Fri, Feb 1, 2019 at 2:58 AM Bjarni J. Vilhjalmsson < notifications@github.com> wrote:

I recommend something between 100K and 2M SNPs. You can find links to summary statistics on LD Hub (http://ldsc.broadinstitute.org/ldhub/) and other places.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/bvilhjal/ldpred/issues/34#issuecomment-459638171, or mute the thread https://github.com/notifications/unsubscribe-auth/AkdJ1oXxPywkfaI_b0TRffsXZ1DXVeVWks5vI_O-gaJpZM4aCJvl .