Skip to content

Implement Garud's G selection statistics for unphased data#1341

Open
sanjaynagi wants to merge 2 commits intosgkit-dev:mainfrom
sanjaynagi:implement-g123-garud-statistic-17-02-26
Open

Implement Garud's G selection statistics for unphased data#1341
sanjaynagi wants to merge 2 commits intosgkit-dev:mainfrom
sanjaynagi:implement-g123-garud-statistic-17-02-26

Conversation

@sanjaynagi
Copy link

After @benjeffery's awesome talk at EIT the other day, I was reminded of a feature I never finished adding to sgkit from over 3 years ago (#980)! not sure how much work is being done on sgkit right now but thought it would be fun to finish it.

In this PR I add the Garud's G statistics GWSS, that are analogous to the Garud's H statistics but for unphased data. In our experience from mosquito genomics, they tend to work very well. G123 is directly analogous to H12, so most of the code is identical to that implementation (please see the issue #980 for more detail).

In the PR i've renamed the _Garud_h() function to _Garud_stat(), as it is applicable to both haplotypes (Garuds H stats) and diplotypes/MLGs (Garuds G stats), and I didn't want to duplicate the code with two separate functions. I have used Nandita Garuds original implementation (SelectionHapStats) to generate expected values for tests from the sgkit simulated dataset.

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.

2 participants

Comments