Cloufield / gwaslab

A Python package for handling and visualizing GWAS summary statistics. https://cloufield.github.io/gwaslab/
GNU General Public License v3.0
119 stars 22 forks source link

regional plot #37

Closed chenyangjjj closed 1 year ago

chenyangjjj commented 1 year ago

Hi, I was making the regional plot with plot_mqq and example data. the script will be stuck when it goes to the "Thu Jun 29 11:56:17 2023 -reference vcf path : /Users/jiangxiaofan/.gwaslab/EAS.ALL.split_norm_af.1kgp3v5.hg19.vcf.gz" .

I have downloaded the reference VCF file. I would like to check is this a version bug or local environment issue?

image

Here is the command I am using that taken from the tutorial. import gwaslab as gl mysumstats = gl.Sumstats("/Users/jiangxiaofan/Desktop/Servers/EADB/GWASlab_analysis/Ref/t2d_bbj.txt.gz", snpid="SNP",chrom="CHR",pos="POS",ea="ALT",nea="REF",neaf="Frq",beta="BETA", se="SE",p="P",direction="Dir",n="N",sep="\t") mysumstats.plot_mqq(mode="r",region=(7,126253550,128253550), region_grid=True,anno=True, anno_args={"rotation":0,"fontsize":12}, vcf_path=gl.get_path("1kg_eas_hg19"))`

Cloufield commented 1 year ago

Hi, Thanks for the question. I am wondering if you installed tabix (http://www.htslib.org/download/) in your environment path? If not, gwaslab will simply scan through the vcf, which takes a very long time. If tabix is available in environment path, it will use .tbi to directly extract the specified region.

chenyangjjj commented 1 year ago

Yes, I believe that's the reason. It finished after waiting over 10mins. Thank you!