stracquadaniolab / baghera

Bayesian Gene Heritability Analysis from GWAS summary statistics
https://baghera.readthedocs.io
MIT License
9 stars 0 forks source link

name 'folder' is not defined #5

Closed gsato3105 closed 2 years ago

gsato3105 commented 2 years ago

I installed using conda baghera-v2.1.11 and received the below error when running baghera on the ldscore_folder and GTF file (step1). ("baghera-tool -h" command work well)

NameError: name 'folder' is not defined

violafanfani commented 2 years ago

Hi @gsato3105, Can you tell me more about what you run and how? Are you following the tutorial? Did you download the data? Have a nice day

gsato3105 commented 2 years ago

Thank you for responce. I'm following the tutorial and try the below command and received the error.

baghera-tool create-files -l data/eur_w_ld_chr/ -a data/gencode.v39.basic.annotation.gtf -s data/snps -g /data/genes

I downloaded eur_w_ld_chr/ from ldsc-github and gtf files from GENCODE

violafanfani commented 2 years ago

Thanks for using BAGHERA and reporting this issue! I have fixed the code and made a patch release. It should be ready on conda after a while. In the meantime, you can download the latest version from github.

gsato3105 commented 2 years ago

I appreciate your swift responce.

Could you tell me how to get liability scale heritability and heritability loci as in your paper? Do I need another software?

violafanfani commented 2 years ago

All the results can be found at zenodo: 'Heritability analysis of the 38 cancers in the UK Biobank' (https://zenodo.org/record/3968269#.Yexay5FKhhE). The heritability loci are those that you can find here :'UKBB_v2/normal_group_top16_significant.csv'. The malignancy.csv table instead contains the genome-wide estimates of heritability on the liability scale for each tumor-type. The estimation of liability-scale heritability does not require any software, on this webpage you will find an easy explanation on how liability and continuous scale compare (http://www.nealelab.is/blog/2017/9/13/heritability-201-types-of-heritability-and-how-we-estimate-it). In practice we are assuming that the sample prevalence is similar to the population one (true for UKBB data) and you only need to use the inverse of the cumulative density function for the normal distribution using the prevalence values (which are also given in the malignancy table). Hope this helps, let me know if you have other questions, Viola

gsato3105 commented 2 years ago

Thanks a lot. Have a nice day!