WansonChoi / HATK

A collection of modules to process and analyze IMGT-HLA sequences.
28 stars 9 forks source link

[HLA_Study.py::ERROR]: Failed to perform logistic regression test on the Binary Markers #14

Closed isabelle-boothman closed 3 years ago

isabelle-boothman commented 3 years ago

Hi when I run HATK after running CookHLA, I get this error: [HLA_Study.py::ERROR]: Failed to perform logistic regression test on the Binary Markers

This is the CookHLA code I ran: $ python CookHLA.py \ -i severe_cADR_chr6_repheno_plink_updatedsex \ -hg 19 \ -o HLA_T1DGC_CookHLA \ -ref T1DGC/T1DGC_REF \ -mem 2g \

-mp 2 # The number of available cores for Multiprocessing.

# -bgl4   # If you want to use Beagle4 instead of Beagle5.

This is the code HATK code I ran: python3 HATK.py \ --variants severe_cADR_chr6_repheno_plink_updatedsex.COPY.LiftDown_hg18 \ --hped HLA_T1DGC_CookHLA.MHC.HLA_IMPUTATION_OUT.hped \ --2field \ --pheno cases_controls_rephenotype.pheno \ --pheno-name ALL \ --out HLA.hatk \ --imgt 3320 \ --hg 19 \ --imgt-dir example/IMGTHLA3320 \ --multiprocess

I'm sure what caused the error, just wondering if anyone knew how to fix it? Thanks

WansonChoi commented 3 years ago

@isabelle-boothman

Hi, thank you for your error report.

Currently, I take care of HATK's maintenance. Could you share the cause?

isabelle-boothman commented 3 years ago

Hi,

Thanks for your reply.

I am not sure what caused the error. I ran CookHLA first using this code: $ python CookHLA.py \ -i /space3/ssr_extra_analysis_space/repheno_plink_files/severe_cADR_epipgx_cpnds_chr6_repheno_plink_updatedsex \ -hg 19 \ -o /space3/ssr_extra_analysis_space/CookHLA_2021/Epipgx_cpnds_HLA_T1DGC_CookHLA \ -ref /usr/local/src/SNP2HLA_package_v1.0.2/T1DGC/T1DGC_REF \ -mem 2g \

-mp 2 # The number of available cores for Multiprocessing.

# -bgl4   # If you want to use Beagle4 instead of Beagle5.

and then I ran HATK using this code:

python3 HATK.py \ --variants /space3/ssr_extra_analysis_space/CookHLA_2021/severe_cADR_epipgx_cpnds_chr6_repheno_plink_updatedsex.COPY.LiftDown_hg18 \ --hped /space3/ssr_extra_analysis_space/CookHLA_2021/Epipgx_cpnds_HLA_T1DGC_CookHLA.MHC.HLA_IMPUTATION_OUT.hped \ --2field \ --pheno /space3/ssr_extra_analysis_space/repheno_plink_files/EpiPGX_CPNDS_cases_controls_rephenotype.pheno \ --pheno-name ALL \ --out /space3/ssr_extra_analysis_space/CookHLA_2021/HATK/Epipgx_cpnds_HLA.hatk \ --imgt 3320 \ --hg 19 \ --imgt-dir example/IMGTHLA3320 \ --multiprocess 2

and got this error: [HLA_Study.py::ERROR]: Failed to perform logistic regression test on the Binary Markers('/space3/ssr_extra_analysis_space/CookHLA_2021/HATK/Epipgx_cpnds_HLA.hatk').

Thanks for all your help.

Best wishes, Isabelle

On Thu, 9 Sept 2021 at 02:08, WansonChoi @.***> wrote:

@isabelle-boothman https://github.com/isabelle-boothman

Hi, thank you for your error report.

Currently, I take care of HATK's maintenance. Could you share the cause?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/WansonChoi/HATK/issues/14#issuecomment-915680495, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANZRSDVUL5BWUEXXP2SJBFTUBACI7ANCNFSM5DLTBMRQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

WansonChoi commented 3 years ago

@isabelle-boothman

I'm sorry, I misunderstood that you found out the cause because you wrote "I'm sure what caused the error, ...".

To investigate the cause, Can you share

(1) the input genotype data('severe_cADR_chr6_repheno_plink_updatedsex.COPY.LiftDown_hg18.{bed,bim,fam}), (2) the imputed hped file('HLA_T1DGC_CookHLA.MHC.HLA_IMPUTATION_OUT.hped'), and (3) the phenotype data('cases_controls_rephenotype.pheno')

if they aren't related to privacy/security issues? (Maybe you can anonymize the sample labels.)

Then, I can investigate the cause more closely. It's hard for me to pinpoint the exact cause only with your argument usages and the error message.

If you can't, then please share the HATK main log file and all intermediate PLINK log files generated in the process.

isabelle-boothman commented 3 years ago

Hi,

So sorry for the delay, but I actually got it working the problem was I had coded my controls as 0 and cases as 1 but they needed to be coded as controls = 1, cases =2,

Thanks again, Isabelle

On Fri, 10 Sept 2021 at 09:26, WansonChoi @.***> wrote:

@isabelle-boothman https://github.com/isabelle-boothman

I'm sorry, I misunderstood that you found out the cause because you wrote "I'm sure what caused the error, ...".

To investigate the cause, Can you share

(1) the input genotype data('severe_cADR_chr6_repheno_plink_updatedsex.COPY.LiftDown_hg18.{bed,bim,fam}), (2) the imputed hped file('HLA_T1DGC_CookHLA.MHC.HLA_IMPUTATION_OUT.hped'), and (3) the phenotype data('cases_controls_rephenotype.pheno')

if they aren't related to privacy/security issues? (Maybe you can anonymize the sample labels.)

Then, I can investigate the cause more closely. It's hard for me to pinpoint the exact cause only with your argument usages and the error message.

If you can't, then please share the HATK main log file and all intermediate PLINK log files generated in the process.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/WansonChoi/HATK/issues/14#issuecomment-916727925, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANZRSDWZ6PKX3KI6EJZOQLDUBG6MTANCNFSM5DLTBMRQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

WansonChoi commented 3 years ago

@isabelle-boothman

Nice! The encoding was the cause and you found it yourself. Maybe I should add a function to check the encoding of a given phenotype file.

Thanks again for your error report and I am closing this issue.