zhengxwen / SNPRelate

R package: parallel computing toolset for relatedness and principal component analysis of SNP data (Development version only)
http://www.bioconductor.org/packages/SNPRelate
98 stars 25 forks source link

SNPs disappearing? #41

Closed blgodwin closed 6 years ago

blgodwin commented 6 years ago

Hi,

I am trying to follow the tutorial. I converted my .vcf to a .gds and tried to prune. I get the following message.

Is there something wrong with the formatting of my .vcf? Thanks!

snpset <- snpgdsLDpruning(genofile, ld.threshold=0.2) SNP pruning based on LD: Excluding 23,103 SNPs on non-autosomes Error in .InitFile2(cmd = paste(ifelse(inherits(gdsobj, "SeqVarGDSClass"), : There is no SNP!

zhengxwen commented 6 years ago

I guess you should try

snpset <- snpgdsLDpruning(genofile, ld.threshold=0.2, autosome.only=FALSE)

since your chromosome codes are not numeric.