Skip to content

unit tests for gwas.py#119

Merged
ttfiliz merged 9 commits intocomorment:mainfrom
ttfiliz:fix116
Jan 24, 2023
Merged

unit tests for gwas.py#119
ttfiliz merged 9 commits intocomorment:mainfrom
ttfiliz:fix116

Conversation

@ttfiliz
Copy link
Contributor

@ttfiliz ttfiliz commented Jan 16, 2023

Fixes #116

Changes proposed in this pull request:

  • Added unit tests for gwas.py based on the use case gwas_demo

Before submitting

  • I've read and followed all steps in the Making a pull request
    section of the CONTRIBUTING docs.
  • I've updated or added any relevant docstrings following the syntax described in the
    Writing docstrings section of the CONTRIBUTING docs.
  • If this PR fixes a bug, I've added a test that will fail without my fix.
  • If this PR adds a new feature, I've added tests that sufficiently cover my new functionality.

@espenhgn espenhgn self-requested a review January 17, 2023 09:11
Copy link
Contributor

@espenhgn espenhgn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @ttfiliz . I'm getting some test errors with this as/REF/ dir doesn't exist from within the container w. py.test -v tests/test_gwas_py.py.

...
Traceback (most recent call last):
  File "/tmp/tmpxw0lxn6n/gwas.py", line 1005, in <module>
    args.func(args, log)
  File "/tmp/tmpxw0lxn6n/gwas.py", line 625, in execute_gwas
    fix_and_validate_pheno_args(args, log)
  File "/tmp/tmpxw0lxn6n/gwas.py", line 224, in fix_and_validate_pheno_args
    check_input_file(args.fam)
  File "/tmp/tmpxw0lxn6n/gwas.py", line 823, in check_input_file
    raise ValueError("Input file does not exist: {f}".format(f=fname))
ValueError: Input file does not exist: /REF/examples/regenie/example_3chr.fam
...

Can you make sure that you don't have host environment variables like SINGULARITY_BIND in effect? Setting this at the Python level explicitly within the test script ought to do I believe(os.environ["SINGULARITY_BIND"] = ...)

@ttfiliz ttfiliz requested a review from espenhgn January 17, 2023 15:02
Copy link
Contributor

@espenhgn espenhgn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, think this is now good to go!

@espenhgn
Copy link
Contributor

@ofrei, can you merge this? I'm fine with it. All tests pass on my end.

@ttfiliz ttfiliz merged commit 0bb5f1a into comorment:main Jan 24, 2023
espenhgn added a commit that referenced this pull request Feb 17, 2023
commit 2dd1c58
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Fri Feb 17 07:28:28 2023 +0000

    updated md5sum

commit 6ceaaf5
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Fri Feb 17 07:26:21 2023 +0000

    rebuild r.sif container

commit 021e333
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Fri Feb 17 07:23:52 2023 +0000

    +PRSice_linux, revise R package repo

commit b984ff6
Merge: 3666140 99d7c0e
Author: deepchocolate <andreas@systerdyster.se>
Date:   Fri Feb 10 15:33:25 2023 +0100

    Merge branch 'deepchocolate/ldpred2_ld'

commit 99d7c0e
Author: deepchocolate <andreas@systerdyster.se>
Date:   Fri Feb 10 13:50:16 2023 +0100

    Added note on filtering

commit f4f7e06
Author: deepchocolate <andreas@systerdyster.se>
Date:   Fri Feb 10 13:40:51 2023 +0100

    Renamed --file-keep-snps to --extract

commit 27413a6
Author: deepchocolate <andreas@systerdyster.se>
Date:   Fri Feb 10 13:27:51 2023 +0100

    Removed --sumstats-sep from test script

commit a94a18a
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Fri Feb 10 10:12:33 2023 +0000

    removed redundant --sumstats-sep arg

commit 3666140
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Thu Feb 9 22:57:39 2023 +0100

    fix flake8 for combine_figures.py

commit f8f904e
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Thu Feb 9 22:54:05 2023 +0100

    noqa: W605

commit 5e3ff1d
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Thu Feb 9 22:51:45 2023 +0100

    manually edit to clear most errors

commit c89ac5b
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Thu Feb 9 21:56:37 2023 +0100

    autopep8 --max-line-length 119 --ignore E302

commit 246ad6b
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Thu Feb 9 23:01:35 2023 +0100

    update config for flake8 linter (#126)

    * test flake8_args

    * Node.js 12 actions are deprecated

    * nonsensical edit that should trigger E501

    * flake8_args

    * bad style

    * check if flake8 is reporting

    * check E302 nontrigger

    * check E302 nontrigger

    * revert things

    * revert gwas.py

    * updated changelog

commit 8f0f2b5
Author: deepchocolate <andreas@systerdyster.se>
Date:   Thu Feb 9 16:04:15 2023 +0100

    Added threshold filtering parameter

commit 92fc902
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Wed Feb 8 11:05:04 2023 +0100

    Allow custom name for IID columns  (#123)

    * clarify comments

    * allow IID column in .pheno file to have a custom name (as defined in .dict file)

    * fix rename_iid_column

    * clarify comments

    * allow IID column in .pheno file to have a custom name (as defined in .dict file)

    * fix rename_iid_column

    * add tests for identical FIDs and custom IIDs

    * also rename pheno.dict iid_column_name

    ---------

    Co-authored-by: ttfiliz <110425985+ttfiliz@users.noreply.github.com>

commit 814db96
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Wed Feb 1 14:52:05 2023 +0000

    some markdown stuff

commit 05f520f
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Wed Feb 1 10:57:38 2023 +0000

    sensible score values. Use plink from container

commit e653381
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Wed Feb 1 10:42:39 2023 +0000

    add --sumstats-sep option etc.

commit 5673a1f
Author: ttfiliz <110425985+ttfiliz@users.noreply.github.com>
Date:   Tue Jan 31 09:58:49 2023 +0100

    throw an error if --variance-standardize is applied to a continuous variable without variation (#121)

commit e70c033
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 31 09:47:58 2023 +0100

    Updated changelog

commit 9ece1f8
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 31 09:47:38 2023 +0100

    Updated LDpred2 README

commit 6e06f24
Author: deepchocolate <andreas@systerdyster.se>
Date:   Thu Jan 26 17:55:33 2023 +0100

    Renamed --geno-file argument

commit 00e8d35
Author: deepchocolate <andreas@systerdyster.se>
Date:   Thu Jan 26 13:56:02 2023 +0100

    Added readme in folder for testdata

commit b6da1a3
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 24 13:22:59 2023 +0100

    Added auto mode to tests

commit 7c1bbf4
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Tue Jan 24 09:11:15 2023 +0100

    Update README.md

commit 0bb5f1a
Author: ttfiliz <110425985+ttfiliz@users.noreply.github.com>
Date:   Tue Jan 24 09:06:18 2023 +0100

    unit tests for gwas.py (#119)

    * Added unit tests for gwas.py

    * change cwd back to original cwd after each test

    * updated changelog

    * set environment variables in test script

    * Update README.md

    * removed unnecessary singularity bind path

    * update README.md

    Co-authored-by: Espen Hagen <2492641+espenhgn@users.noreply.github.com>

commit 31036f8
Author: deepchocolate <andreas@systerdyster.se>
Date:   Wed Jan 11 15:22:51 2023 +0100

    Added sampling of individuals

commit bb8f80d
Author: deepchocolate <andreas@systerdyster.se>
Date:   Wed Jan 11 14:45:18 2023 +0100

    Removed redundant code, fixed chr2use argument

commit ea54fff
Author: deepchocolate <andreas@systerdyster.se>
Date:   Wed Jan 11 14:26:07 2023 +0100

    Cleanup, fixed arguments to --sumstats

commit 82d39c1
Author: deepchocolate <andreas@systerdyster.se>
Date:   Wed Jan 11 14:25:35 2023 +0100

    Reorganized tests

commit 896eadf
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 10 20:39:57 2023 +0100

    Added test runs

commit 304f19a
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 10 17:24:22 2023 +0100

    Working version

commit 6b47b30
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 10 10:55:55 2023 +0100

    Added test runs

commit 087d50f
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 10 10:55:25 2023 +0100

    Trimmed some output
espenhgn added a commit that referenced this pull request Feb 20, 2023
commit 4f7a26a
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Mon Feb 20 09:29:28 2023 +0000

    added pROC library

commit 2dd1c58
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Fri Feb 17 07:28:28 2023 +0000

    updated md5sum

commit 6ceaaf5
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Fri Feb 17 07:26:21 2023 +0000

    rebuild r.sif container

commit 021e333
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Fri Feb 17 07:23:52 2023 +0000

    +PRSice_linux, revise R package repo

commit b984ff6
Merge: 3666140 99d7c0e
Author: deepchocolate <andreas@systerdyster.se>
Date:   Fri Feb 10 15:33:25 2023 +0100

    Merge branch 'deepchocolate/ldpred2_ld'

commit 99d7c0e
Author: deepchocolate <andreas@systerdyster.se>
Date:   Fri Feb 10 13:50:16 2023 +0100

    Added note on filtering

commit f4f7e06
Author: deepchocolate <andreas@systerdyster.se>
Date:   Fri Feb 10 13:40:51 2023 +0100

    Renamed --file-keep-snps to --extract

commit 27413a6
Author: deepchocolate <andreas@systerdyster.se>
Date:   Fri Feb 10 13:27:51 2023 +0100

    Removed --sumstats-sep from test script

commit a94a18a
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Fri Feb 10 10:12:33 2023 +0000

    removed redundant --sumstats-sep arg

commit 3666140
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Thu Feb 9 22:57:39 2023 +0100

    fix flake8 for combine_figures.py

commit f8f904e
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Thu Feb 9 22:54:05 2023 +0100

    noqa: W605

commit 5e3ff1d
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Thu Feb 9 22:51:45 2023 +0100

    manually edit to clear most errors

commit c89ac5b
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Thu Feb 9 21:56:37 2023 +0100

    autopep8 --max-line-length 119 --ignore E302

commit 246ad6b
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Thu Feb 9 23:01:35 2023 +0100

    update config for flake8 linter (#126)

    * test flake8_args

    * Node.js 12 actions are deprecated

    * nonsensical edit that should trigger E501

    * flake8_args

    * bad style

    * check if flake8 is reporting

    * check E302 nontrigger

    * check E302 nontrigger

    * revert things

    * revert gwas.py

    * updated changelog

commit 8f0f2b5
Author: deepchocolate <andreas@systerdyster.se>
Date:   Thu Feb 9 16:04:15 2023 +0100

    Added threshold filtering parameter

commit 92fc902
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Wed Feb 8 11:05:04 2023 +0100

    Allow custom name for IID columns  (#123)

    * clarify comments

    * allow IID column in .pheno file to have a custom name (as defined in .dict file)

    * fix rename_iid_column

    * clarify comments

    * allow IID column in .pheno file to have a custom name (as defined in .dict file)

    * fix rename_iid_column

    * add tests for identical FIDs and custom IIDs

    * also rename pheno.dict iid_column_name

    ---------

    Co-authored-by: ttfiliz <110425985+ttfiliz@users.noreply.github.com>

commit 814db96
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Wed Feb 1 14:52:05 2023 +0000

    some markdown stuff

commit 05f520f
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Wed Feb 1 10:57:38 2023 +0000

    sensible score values. Use plink from container

commit e653381
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Wed Feb 1 10:42:39 2023 +0000

    add --sumstats-sep option etc.

commit 5673a1f
Author: ttfiliz <110425985+ttfiliz@users.noreply.github.com>
Date:   Tue Jan 31 09:58:49 2023 +0100

    throw an error if --variance-standardize is applied to a continuous variable without variation (#121)

commit e70c033
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 31 09:47:58 2023 +0100

    Updated changelog

commit 9ece1f8
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 31 09:47:38 2023 +0100

    Updated LDpred2 README

commit 6e06f24
Author: deepchocolate <andreas@systerdyster.se>
Date:   Thu Jan 26 17:55:33 2023 +0100

    Renamed --geno-file argument

commit 00e8d35
Author: deepchocolate <andreas@systerdyster.se>
Date:   Thu Jan 26 13:56:02 2023 +0100

    Added readme in folder for testdata

commit b6da1a3
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 24 13:22:59 2023 +0100

    Added auto mode to tests

commit 7c1bbf4
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Tue Jan 24 09:11:15 2023 +0100

    Update README.md

commit 0bb5f1a
Author: ttfiliz <110425985+ttfiliz@users.noreply.github.com>
Date:   Tue Jan 24 09:06:18 2023 +0100

    unit tests for gwas.py (#119)

    * Added unit tests for gwas.py

    * change cwd back to original cwd after each test

    * updated changelog

    * set environment variables in test script

    * Update README.md

    * removed unnecessary singularity bind path

    * update README.md

    Co-authored-by: Espen Hagen <2492641+espenhgn@users.noreply.github.com>

commit 31036f8
Author: deepchocolate <andreas@systerdyster.se>
Date:   Wed Jan 11 15:22:51 2023 +0100

    Added sampling of individuals

commit bb8f80d
Author: deepchocolate <andreas@systerdyster.se>
Date:   Wed Jan 11 14:45:18 2023 +0100

    Removed redundant code, fixed chr2use argument

commit ea54fff
Author: deepchocolate <andreas@systerdyster.se>
Date:   Wed Jan 11 14:26:07 2023 +0100

    Cleanup, fixed arguments to --sumstats

commit 82d39c1
Author: deepchocolate <andreas@systerdyster.se>
Date:   Wed Jan 11 14:25:35 2023 +0100

    Reorganized tests

commit 896eadf
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 10 20:39:57 2023 +0100

    Added test runs

commit 304f19a
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 10 17:24:22 2023 +0100

    Working version

commit 6b47b30
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 10 10:55:55 2023 +0100

    Added test runs

commit 087d50f
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 10 10:55:25 2023 +0100

    Trimmed some output
espenhgn added a commit that referenced this pull request Oct 17, 2023
* install LDAK

* W.I.P.

* not implemented LDAK test

* add missing .eigenvec file

* add some R scripts

* PGS using prsice2

* backup w.i.p.

* backing up files

* work in progress

* work in progress

* rebuild gwas.sif including ldak tool

* rebuild r.sif with PRSice_linux binary

* backup

* hidden functions return strings

* work in progress

* Work in progress

* w.i.p.

* w.i.p.

* w.i.p.

* script updates + config.yaml file

* w.i.p.

* simplify notebook

* w.i.p.

* w.i.p.

* linting

* linting

* linting

* fuck

* post_run using python container

* add runtime script for interactive use

* some flexibility w Eigenvec_file

* add option for bash and slurm jobs

* ldpred2.R script from main branch

* BasePGRS->BasePGS

* backin up

* fixed application with synthetic data

* cleanup

* backing up

* don't use log object from outer scope

* fix parallelization

* code that should run on TSD

* remove Data_postfix arg in main classes

* adapting PGS/pgs as common term

* PRS -> PGS etc.

* renamed file

* updating pgs_exec w. example

* some user example script updates

* subparser added for method specific

* updates to usage

* Input_dir/Data_prefix to Geno_file

* rebuilt container, tee build logs

* linting

* suppress some CI warnings

* setup-python@v4

* add R script for evaluating model fit

* make Phenotype mandatory arg

* sep

* df.merge stuff

* backup

* add some example on MoBa

* fit lm model <pheno>~PGS+PC1+...+PCN+<cov>

* move R scripts to Rscripts dir

* write results to "results"

* get rid of semiredundant kwargs

* do not autoasses #cores

* use env variables

* fixes

* disgusting

* path things

* chromosomes

* minor formatting

* w.i.p.

* reformatting env setup

* paths

* clump and a2->a0 fixes

* minifixes

* Squashed commit of the following:

commit 2dd1c58
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Fri Feb 17 07:28:28 2023 +0000

    updated md5sum

commit 6ceaaf5
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Fri Feb 17 07:26:21 2023 +0000

    rebuild r.sif container

commit 021e333
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Fri Feb 17 07:23:52 2023 +0000

    +PRSice_linux, revise R package repo

commit b984ff6
Merge: 3666140 99d7c0e
Author: deepchocolate <andreas@systerdyster.se>
Date:   Fri Feb 10 15:33:25 2023 +0100

    Merge branch 'deepchocolate/ldpred2_ld'

commit 99d7c0e
Author: deepchocolate <andreas@systerdyster.se>
Date:   Fri Feb 10 13:50:16 2023 +0100

    Added note on filtering

commit f4f7e06
Author: deepchocolate <andreas@systerdyster.se>
Date:   Fri Feb 10 13:40:51 2023 +0100

    Renamed --file-keep-snps to --extract

commit 27413a6
Author: deepchocolate <andreas@systerdyster.se>
Date:   Fri Feb 10 13:27:51 2023 +0100

    Removed --sumstats-sep from test script

commit a94a18a
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Fri Feb 10 10:12:33 2023 +0000

    removed redundant --sumstats-sep arg

commit 3666140
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Thu Feb 9 22:57:39 2023 +0100

    fix flake8 for combine_figures.py

commit f8f904e
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Thu Feb 9 22:54:05 2023 +0100

    noqa: W605

commit 5e3ff1d
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Thu Feb 9 22:51:45 2023 +0100

    manually edit to clear most errors

commit c89ac5b
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Thu Feb 9 21:56:37 2023 +0100

    autopep8 --max-line-length 119 --ignore E302

commit 246ad6b
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Thu Feb 9 23:01:35 2023 +0100

    update config for flake8 linter (#126)

    * test flake8_args

    * Node.js 12 actions are deprecated

    * nonsensical edit that should trigger E501

    * flake8_args

    * bad style

    * check if flake8 is reporting

    * check E302 nontrigger

    * check E302 nontrigger

    * revert things

    * revert gwas.py

    * updated changelog

commit 8f0f2b5
Author: deepchocolate <andreas@systerdyster.se>
Date:   Thu Feb 9 16:04:15 2023 +0100

    Added threshold filtering parameter

commit 92fc902
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Wed Feb 8 11:05:04 2023 +0100

    Allow custom name for IID columns  (#123)

    * clarify comments

    * allow IID column in .pheno file to have a custom name (as defined in .dict file)

    * fix rename_iid_column

    * clarify comments

    * allow IID column in .pheno file to have a custom name (as defined in .dict file)

    * fix rename_iid_column

    * add tests for identical FIDs and custom IIDs

    * also rename pheno.dict iid_column_name

    ---------

    Co-authored-by: ttfiliz <110425985+ttfiliz@users.noreply.github.com>

commit 814db96
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Wed Feb 1 14:52:05 2023 +0000

    some markdown stuff

commit 05f520f
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Wed Feb 1 10:57:38 2023 +0000

    sensible score values. Use plink from container

commit e653381
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Wed Feb 1 10:42:39 2023 +0000

    add --sumstats-sep option etc.

commit 5673a1f
Author: ttfiliz <110425985+ttfiliz@users.noreply.github.com>
Date:   Tue Jan 31 09:58:49 2023 +0100

    throw an error if --variance-standardize is applied to a continuous variable without variation (#121)

commit e70c033
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 31 09:47:58 2023 +0100

    Updated changelog

commit 9ece1f8
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 31 09:47:38 2023 +0100

    Updated LDpred2 README

commit 6e06f24
Author: deepchocolate <andreas@systerdyster.se>
Date:   Thu Jan 26 17:55:33 2023 +0100

    Renamed --geno-file argument

commit 00e8d35
Author: deepchocolate <andreas@systerdyster.se>
Date:   Thu Jan 26 13:56:02 2023 +0100

    Added readme in folder for testdata

commit b6da1a3
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 24 13:22:59 2023 +0100

    Added auto mode to tests

commit 7c1bbf4
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Tue Jan 24 09:11:15 2023 +0100

    Update README.md

commit 0bb5f1a
Author: ttfiliz <110425985+ttfiliz@users.noreply.github.com>
Date:   Tue Jan 24 09:06:18 2023 +0100

    unit tests for gwas.py (#119)

    * Added unit tests for gwas.py

    * change cwd back to original cwd after each test

    * updated changelog

    * set environment variables in test script

    * Update README.md

    * removed unnecessary singularity bind path

    * update README.md

    Co-authored-by: Espen Hagen <2492641+espenhgn@users.noreply.github.com>

commit 31036f8
Author: deepchocolate <andreas@systerdyster.se>
Date:   Wed Jan 11 15:22:51 2023 +0100

    Added sampling of individuals

commit bb8f80d
Author: deepchocolate <andreas@systerdyster.se>
Date:   Wed Jan 11 14:45:18 2023 +0100

    Removed redundant code, fixed chr2use argument

commit ea54fff
Author: deepchocolate <andreas@systerdyster.se>
Date:   Wed Jan 11 14:26:07 2023 +0100

    Cleanup, fixed arguments to --sumstats

commit 82d39c1
Author: deepchocolate <andreas@systerdyster.se>
Date:   Wed Jan 11 14:25:35 2023 +0100

    Reorganized tests

commit 896eadf
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 10 20:39:57 2023 +0100

    Added test runs

commit 304f19a
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 10 17:24:22 2023 +0100

    Working version

commit 6b47b30
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 10 10:55:55 2023 +0100

    Added test runs

commit 087d50f
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 10 10:55:25 2023 +0100

    Trimmed some output

* revert gwas.py to main branch

* multithreading

* multithreading

* fixes

* fix action

* Squashed commit of the following:

commit 4f7a26a
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Mon Feb 20 09:29:28 2023 +0000

    added pROC library

commit 2dd1c58
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Fri Feb 17 07:28:28 2023 +0000

    updated md5sum

commit 6ceaaf5
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Fri Feb 17 07:26:21 2023 +0000

    rebuild r.sif container

commit 021e333
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Fri Feb 17 07:23:52 2023 +0000

    +PRSice_linux, revise R package repo

commit b984ff6
Merge: 3666140 99d7c0e
Author: deepchocolate <andreas@systerdyster.se>
Date:   Fri Feb 10 15:33:25 2023 +0100

    Merge branch 'deepchocolate/ldpred2_ld'

commit 99d7c0e
Author: deepchocolate <andreas@systerdyster.se>
Date:   Fri Feb 10 13:50:16 2023 +0100

    Added note on filtering

commit f4f7e06
Author: deepchocolate <andreas@systerdyster.se>
Date:   Fri Feb 10 13:40:51 2023 +0100

    Renamed --file-keep-snps to --extract

commit 27413a6
Author: deepchocolate <andreas@systerdyster.se>
Date:   Fri Feb 10 13:27:51 2023 +0100

    Removed --sumstats-sep from test script

commit a94a18a
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Fri Feb 10 10:12:33 2023 +0000

    removed redundant --sumstats-sep arg

commit 3666140
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Thu Feb 9 22:57:39 2023 +0100

    fix flake8 for combine_figures.py

commit f8f904e
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Thu Feb 9 22:54:05 2023 +0100

    noqa: W605

commit 5e3ff1d
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Thu Feb 9 22:51:45 2023 +0100

    manually edit to clear most errors

commit c89ac5b
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Thu Feb 9 21:56:37 2023 +0100

    autopep8 --max-line-length 119 --ignore E302

commit 246ad6b
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Thu Feb 9 23:01:35 2023 +0100

    update config for flake8 linter (#126)

    * test flake8_args

    * Node.js 12 actions are deprecated

    * nonsensical edit that should trigger E501

    * flake8_args

    * bad style

    * check if flake8 is reporting

    * check E302 nontrigger

    * check E302 nontrigger

    * revert things

    * revert gwas.py

    * updated changelog

commit 8f0f2b5
Author: deepchocolate <andreas@systerdyster.se>
Date:   Thu Feb 9 16:04:15 2023 +0100

    Added threshold filtering parameter

commit 92fc902
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Wed Feb 8 11:05:04 2023 +0100

    Allow custom name for IID columns  (#123)

    * clarify comments

    * allow IID column in .pheno file to have a custom name (as defined in .dict file)

    * fix rename_iid_column

    * clarify comments

    * allow IID column in .pheno file to have a custom name (as defined in .dict file)

    * fix rename_iid_column

    * add tests for identical FIDs and custom IIDs

    * also rename pheno.dict iid_column_name

    ---------

    Co-authored-by: ttfiliz <110425985+ttfiliz@users.noreply.github.com>

commit 814db96
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Wed Feb 1 14:52:05 2023 +0000

    some markdown stuff

commit 05f520f
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Wed Feb 1 10:57:38 2023 +0000

    sensible score values. Use plink from container

commit e653381
Author: Espen Hagen <2492641+espenhgn@users.noreply.github.com>
Date:   Wed Feb 1 10:42:39 2023 +0000

    add --sumstats-sep option etc.

commit 5673a1f
Author: ttfiliz <110425985+ttfiliz@users.noreply.github.com>
Date:   Tue Jan 31 09:58:49 2023 +0100

    throw an error if --variance-standardize is applied to a continuous variable without variation (#121)

commit e70c033
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 31 09:47:58 2023 +0100

    Updated changelog

commit 9ece1f8
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 31 09:47:38 2023 +0100

    Updated LDpred2 README

commit 6e06f24
Author: deepchocolate <andreas@systerdyster.se>
Date:   Thu Jan 26 17:55:33 2023 +0100

    Renamed --geno-file argument

commit 00e8d35
Author: deepchocolate <andreas@systerdyster.se>
Date:   Thu Jan 26 13:56:02 2023 +0100

    Added readme in folder for testdata

commit b6da1a3
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 24 13:22:59 2023 +0100

    Added auto mode to tests

commit 7c1bbf4
Author: Oleksandr Frei <oleksandr.frei@gmail.com>
Date:   Tue Jan 24 09:11:15 2023 +0100

    Update README.md

commit 0bb5f1a
Author: ttfiliz <110425985+ttfiliz@users.noreply.github.com>
Date:   Tue Jan 24 09:06:18 2023 +0100

    unit tests for gwas.py (#119)

    * Added unit tests for gwas.py

    * change cwd back to original cwd after each test

    * updated changelog

    * set environment variables in test script

    * Update README.md

    * removed unnecessary singularity bind path

    * update README.md

    Co-authored-by: Espen Hagen <2492641+espenhgn@users.noreply.github.com>

commit 31036f8
Author: deepchocolate <andreas@systerdyster.se>
Date:   Wed Jan 11 15:22:51 2023 +0100

    Added sampling of individuals

commit bb8f80d
Author: deepchocolate <andreas@systerdyster.se>
Date:   Wed Jan 11 14:45:18 2023 +0100

    Removed redundant code, fixed chr2use argument

commit ea54fff
Author: deepchocolate <andreas@systerdyster.se>
Date:   Wed Jan 11 14:26:07 2023 +0100

    Cleanup, fixed arguments to --sumstats

commit 82d39c1
Author: deepchocolate <andreas@systerdyster.se>
Date:   Wed Jan 11 14:25:35 2023 +0100

    Reorganized tests

commit 896eadf
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 10 20:39:57 2023 +0100

    Added test runs

commit 304f19a
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 10 17:24:22 2023 +0100

    Working version

commit 6b47b30
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 10 10:55:55 2023 +0100

    Added test runs

commit 087d50f
Author: deepchocolate <andreas@systerdyster.se>
Date:   Tue Jan 10 10:55:25 2023 +0100

    Trimmed some output

* ncores

* split in two scripts

* fixes

* add clump_field parameter to PGS_plink

* disable sorting while merging

* remove use of --pheno-file and --col-pheno

* fixes

* notebooks

* newline

* added gtsummary r package

* added R flextable

* added R parameters

* cleanup merge

* better r lib test, PR cleanup

* formatting

* added R2 calcs

* removed outdated ldpred2 files

* renaming params

* renaming variable nems etc.

* clean up variable names

* eigenvec file stuff

* fixes

* moving files

* updated .gitignore

* nPCs

* cleanup

* comment

* misc updates

* posit cran clone, new R libraries

* fixing build

* rebuilt r.sif container

* linting

* linting

* add more R stuff

* docs

* plink score_args -> score_columns

* cleanup

* limit PLINK cpu usage

* wrap up R packages

* updated r.sif build procedure and scripts

* update R build recipes and test

* rebuilt r.sif

* hadolint

* better crash handling, explicit args w. createBackingFile.R

* docs, deal with prsice2 bar-levels/fastscore

* updated MoBa scripts

* added lm/glm fits/stats w.o. covariates; ORs

* details on output

* string formatting

* MplusAutomation/PredictABEL added to r.sif

* rebuilt r.sif

* roll back install_minimac4.sh script to main

* removed non-lfs file (will re-add)

* prep add EUR.eigenvec file

* Add missing PRSice2 tutorial file

* updated changelog w. main changes

* github  markdown math

* typo

* better math formatting w. sphinx

* got rid of a myst-parser warning

* flake8 fix

* fixed broken test of createBackingFile.R
@ttfiliz ttfiliz deleted the fix116 branch March 11, 2024 08:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Implement unit tests for gwas.py

3 participants