Skip to content

Commit cbce7e6

Browse files
Merge pull request #214 from AlphaGenes/devel
Devel work from @XingerTang @AprilYUZhang and @RosCraddock and me!
2 parents 1c56d89 + 4975c21 commit cbce7e6

File tree

309 files changed

+80090
-41539
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

309 files changed

+80090
-41539
lines changed

.flake8

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
[flake8]
2+
# Black by its default setting the maximum length to 88
3+
max-line-length = 88
4+
extend-ignore =
5+
# also the Black's default, whitespace before ':'
6+
E203,
7+
# this is for the line length, all the lines too long are comments now
8+
E501

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
*.1 linguist-documentation

.github/workflows/publish.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,14 @@ jobs:
3131
- name: Build SDist and wheel
3232
run: python3 -m build
3333

34-
- uses: actions/upload-artifact@v3
34+
- uses: actions/upload-artifact@v4
3535
with:
3636
path: dist/*
3737

3838
- name: Check metadata
3939
run: pipx run twine check dist/*
4040

41-
- uses: actions/download-artifact@v3
41+
- uses: actions/download-artifact@v4
4242
with:
4343
name: artifact
4444
path: dist

.github/workflows/tests.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: Evaluate code syntax and correctness
2+
on: [push, pull_request]
3+
4+
jobs:
5+
pre-commit_and_pytest:
6+
name: Run pre-commit and pytest
7+
strategy:
8+
matrix:
9+
os: [ubuntu-latest, Windows-latest, macos-latest]
10+
runs-on: ${{ matrix.os }}
11+
permissions:
12+
contents: read
13+
14+
steps:
15+
- uses: actions/checkout@v3
16+
- name: Set up Python
17+
uses: actions/setup-python@v4
18+
with:
19+
python-version: "3.11.x"
20+
21+
- uses: pre-commit/action@v3.0.0
22+
name: Run pre-commit
23+
24+
- name: Install pypa/build
25+
run: >-
26+
python3 -m
27+
pip install
28+
--upgrade
29+
build
30+
31+
- name: Initialize submodules
32+
run: |
33+
git submodule update --init
34+
35+
- name: Build SDist and wheel
36+
run: python3 -m build
37+
38+
- name: Install AlphaPeel
39+
run: pip install dist/alphapeel-1.3.0-py3-none-any.whl
40+
41+
- name: Install pytest
42+
run: |
43+
pip install pytest
44+
pip install pytest-benchmark
45+
46+
- name: Run pytest
47+
run: |
48+
pytest

.gitignore

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,3 +11,15 @@ build/
1111
docs/build/
1212
example/outputs
1313
AlphaPeel_env
14+
tests/functional_tests/**/outputs/
15+
tests/functional_tests/**/outputs/**
16+
tests/accuracy_tests/outputs/
17+
tests/accuracy_tests/outputs/**
18+
.pytest_cache
19+
tests/accuracy_tests/accu_report.txt
20+
.Rproj.user
21+
**/.RData
22+
**/.Rhistory
23+
**/*.Rproj
24+
**/segfile.txt
25+
tests/accuracy_tests/sim_for_alphapeel_accu_test/seg_file.txt

.pre-commit-config.yaml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
repos:
2+
- repo: https://github.com/psf/black
3+
rev: 23.7.0
4+
hooks:
5+
- id: black
6+
- repo: https://github.com/PyCQA/flake8
7+
rev: 6.0.0
8+
hooks:
9+
- id: flake8

.readthedocs.yaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@ build:
1111
sphinx:
1212
configuration: docs/source/conf.py
1313

14+
python:
15+
install:
16+
- requirements: docs/source/requirements.txt
17+
1418
formats:
15-
- pdf
1619
- epub

Changelog.md

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
2+
# Changelog
3+
4+
5+
## [1.2.0] - 2025-03-21
6+
**New features**
7+
* allow metafounders, defined as “MF_”, in the pedigree file input ({pr}`175`, {user}`RosCraddock`, {user}`XingerTang`)
8+
9+
* added ``alt_allele_prob_file`` to allow user-inputted alternative allele frequencies for each metafounder and loci. For now, these are restricted to be between 0.01 and 0.99 ({pr}`175`, {user}`RosCraddock`, {user}`XingerTang`)
10+
11+
* added ``main_metafounder`` to allow user to assign the default metafounder to use where a metafounder has not been assigned to a founder in the pedigree ({pr}`175`, {user}`RosCraddock`, {user}`XingerTang`)
12+
13+
* added ``update_alt_allele_prob`` to allow the base alternative allele frequencies to be updated after each peeling cycle based on the mean of the founders within the assigned metafounder ({pr}`182`, {user}`RosCraddock`)
14+
15+
**Bug fixes**
16+
* Fixed bug due to setuptools package being updated for all wheel file naming to follow binary distribution specification (i.e all lower case) and updated documentation ({pr}`182`, {user}`RosCraddock`)
17+
18+
**Maintenance**
19+
* User-warnings and documentation updates for metafounder implementation and estimation of alternative allele frequency ({pr} `152`, {pr}`175`, {pr}`182`, {user}`RosCraddock`, {user}`XingerTang`)
20+
21+
* Functional and accuracy tests for metafounder implementation ({pr}`156`, {pr}`182`, {user}`XingerTang`, {user}`RosCraddock`)
22+
23+
* Updated reference to tinyhouse ({pr}`177`, {user}`XingerTang`)
24+
25+
26+
## [1.1.6] - 2024-10-22
27+
**New features**
28+
* Addition of map file input for non-hybrid mode ({pr}`154`, {user}`XingerTang`)
29+
30+
**Bug fixes**
31+
* resolved bug to produce output file with ``-hap`` and ``-geno`` ({pr}`157`, {user}`AprilYUZhang`)
32+
33+
**Maintenance**
34+
* set default hap and geno threshold as 1/3 when calling genotypes ({pr}`157`, {user}`AprilYUZhang`)
35+
36+
## [1.1.5] - 2023-12-01
37+
**New features**
38+
* Addition of output options: ``geno``, and ``hap_threshold`` ({pr}`119`, {user}``AprilYuZhang`)
39+
40+
**Maintenance**
41+
* Updates in option and file names. These include:
42+
43+
* ``no_dosages`` to ``no_dosage``
44+
* ``calling_threshold`` to ``geno_threshold``
45+
* ``call_phase`` to ``hap``
46+
* ``haps`` to ``phased_geno_prob``
47+
* ``pedigree`` to ``ped_file``
48+
* ``genotypes`` to ``geno_file``
49+
* and more, for all changes please visit: https://github.com/AlphaGenes/AlphaPeel/issues/113#issue-1935197000 ({pr}`105`, {pr}`115`, {pr}`122`, {user}`XingerTang`, {user}`AprilYuZhang`)
50+
51+
* Updates the documentation and help functions ({pr}`88`, {pr}`119`, {user}`XingerTang`, {user}`AprilYuZhang`).
52+
53+
* Updates to accuracy and functional tests for new argument names ({pr}`126`, {pr}`130`, {pr}`131`, {user}`XingerTang`).
54+
55+
## [1.1.4] - 2023-08-25
56+
**New features**
57+
* Implementation of functional and accuracy testing with pytest ({pr}`53`, {user}`XingerTang`)
58+
59+
* Implementation of pre-committ protocol through Black and Flake8 ({pr}`40`, {user}`XingerTang`)
60+
61+
* Implementation of cross-platform tests workflow through github actions ({pr}`59`, {user}`XingerTang`)
62+
63+
* Added instructions for how to contribute to AlphaPeel ({pr}`27`, {pr}`31`, {user}`XingerTang`)
64+
65+
**Bug Fixes**
66+
* Fixed bug on the loading of submodule ({pr}`22`, {user}`XingerTang`)
67+
68+
**Maintenance**
69+
* Update theme for the HTML documentation ({pr}`38`, {user}`XingerTang`)
70+
71+
* Modified the URL for installation ({pr}`11`, {user}`XingerTang`)

README.md

Lines changed: 5 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# AlphaPeel
22

3+
<a href="https://alphapeel.readthedocs.io/en/latest/index.html">
4+
<img src="https://app.readthedocs.org/projects/alphapeel/badge/"/>
5+
</a>
6+
37
AlphaPeel is a software package for calling, phasing, and imputing genotype and sequence data in pedigree populations. This program implements single-locus peeling, multi-locus peeling, and hybrid peeling. A complete description of these methods is given in the suggested citation:
48

59
Whalen, A, Ros-Freixedes, R, Wilson, DL, Gorjanc, G, Hickey, JM. (2018). Hybrid peeling for fast and accurate calling, phasing, and imputation with sequence data of any coverage in pedigrees. Genetics Selection Evolution; doi: <a href="https://doi.org/10.1186/s12711-018-0438-2">https://doi.org/10.1186/s12711-018-0438-2</a>
@@ -20,38 +24,4 @@ AlphaPeel is fully and freely available for all use under the MIT License.
2024

2125
## Installation
2226

23-
AlphaPeel is available on [PyPI](https://pypi.org/project/AlphaPeel):
24-
25-
pip install AlphaPeel
26-
27-
## Distribution
28-
29-
Wheel distribution and source distribution are both available on [PyPI](https://pypi.org/project/AlphaPeel/#files).
30-
31-
## Build wheels
32-
33-
If you want to build the wheels yourself, we require an installation of Python 3 and you need to fork and clone the repository to your local directory first (see [user guide](https://alphapeel.readthedocs.io/en/latest/contribute.html#fork-the-repository))
34-
35-
Run the following to build the wheel distribution and the source distribution of the package.
36-
37-
First, create the virtual environment:
38-
39-
python3 -m venv AlphaPeel_env
40-
41-
Next, activate the environment:
42-
43-
source AlphaPeel_env/bin/activate
44-
45-
Install build:
46-
47-
python3 -m pip install --upgrade build
48-
49-
Build the distribution:
50-
51-
python3 -m build
52-
53-
Now, the distributions of AlphaPeel should be available in ``dist/``.
54-
55-
Finally, deactivate the environment:
56-
57-
deactivate
27+
See https://alphapeel.readthedocs.io/en/latest/get_started.html#install-software

0 commit comments

Comments
 (0)