MRCIEU / gwasglue

Linking GWAS data to analytical tools in R
Other
112 stars 39 forks source link

gwasvcf_to_finemapr error: Input is not detected as bcf or vcf format #40 #35

Open JonnyBaseball opened 1 year ago

JonnyBaseball commented 1 year ago
  1. Using your vignette, downloading ieu-a-300.vcf.gz ([from (https://gwas.mrcieu.ac.uk/datasets/ieu-a-300/) (also your vignette region, vcffile, bfile and plink-bin)

dat <- gwasvcf_to_finemapr(region = region$region, vcf=vcffile, bfile=bfile, plink_bin=plink_bin)

Extracting data from vcf Failed to open /Users/dr/Desktop/ieu-a-300.vcf.gz: could not load index [E::COMPAT_bcf_hdr_read] Input is not detected as bcf or vcf format Error in h(simpleError(msg, call)) : error in evaluating the argument 'x' in selecting a method for function 'seqinfo': no 'header' line "#CHROM POS ID..."?

  1. Using a vcf file created from gwas txt file

vv %$% create_vcf(chrom=seqnames, pos=start, nea=REF, ea=ALT, snp=ID, ea_af=AF, effect=ES, se=SE, pval=10^-LP, n=SS, name="a")

With same gwasvcf_to_finemapr, following error occurred:

Extracting data from vcf Error in h(simpleError(msg, call)) : error in evaluating the argument 'object' in selecting a method for function 'samples': [internal] _hts_rewind() failed

Any help would be appreciated! Thanks